Date Conversion

Nigel.

From post #1 in this thread…
>>A couple of the fields are date formats but the source data has them has dd.mm.yyyy<<

And that is the specification as supplied by Andrew.

Chris.
 
In other words convert from dd.mm.yyyy to dd/mm/yyyy which is why I initially said that the OP could also try a different method which would not require any coding.

It could be tried and, if it did what was required, then all well and good. If it failed there is still the function to use.
 
The import dialog handles dates in many formats. When the dialog opens, click the advanced button. To get to the place where you can set the date format. Choose the dmy option and the dot as the separator
attachment.php

Then scroll through the columns and change the data type to date (you may be able to do this in the first dialog where you set the date by changing text to date as the data type.
attachment.php

Then looking at the table it shows the date as m/d/y because that is my system date format.
attachment.php


No coding required if you do it when you import the data. You can save the import spec and then reference it in the TransferText method to automate the task.
 

Attachments

  • ImportDialogPg1.jpg
    ImportDialogPg1.jpg
    81.7 KB · Views: 255
  • ImportDialogPg2.jpg
    ImportDialogPg2.jpg
    66.6 KB · Views: 242
  • ImportDialogPg3.jpg
    ImportDialogPg3.jpg
    17.7 KB · Views: 220

Users who are viewing this thread

Back
Top Bottom