0

I need to store ISO 8601 recurrence (something like R/20130325T06/P1D) to a table. this table stores different recurring jobs that needs to be executed.

Is there any native data type mysql (or any other db for the knowledge) that can be used to store this data other than VARCHAR data type.

4
  • 1
    There is no native datatype for this data type in SQL. – Akina Apr 8 '20 at 8:27
  • as long as you can convert it both ways, you don't need it, when you need calculation on dates and time you have to use the mysql Datatyp Date, Datetime,Timestamp – nbk Apr 8 '20 at 14:36
  • If you are simply storing and retrieving it, then VARCHAR. If you need to get the date/time/etc, then you are on your own. Nothing in MySQL understands ISO 8601. – Rick James Apr 15 '20 at 5:32
  • Thanks for all the comment, we went ahead with VARCHAR for this. basically it is the store/retrieve what we are looking at – Amila Banuka Amarasinghe Apr 16 '20 at 9:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.