April 12, 201213 yr I need to export text that shows date and time in the format : "yyyy-mm-dd hh:mm:ss" The best formula I have found so far for the calculation field is "Year ( DateStart ) & "-" & Month ( DateStart ) & "-" & Day ( DateStart )& " " & TimeStart" However this gives results like ""2012-4-23 10:00:00" which has the problem of the month only having one digit when I need it to have two. Any ideas for resolving this? I also have the problem that the exported text should have a UNIX LF end of carriage instead of a Macintosh end of line. Can you implement a UNIX LF end of carriage from within FMP?
April 12, 201213 yr Use this expression to add leading zeros... Right( "00" & Month( DateStart ) ; 2 )
April 12, 201213 yr Let ( [ Date = YourDate ; y = Year ( Date ) ; m = Right ( 0 & Month ( Date ) ; 2 ) ; d = Right ( 0 & Day ( Date ) ; 2 ) ] ; y & "-" & m & "-" & d )
April 13, 201213 yr Author Great thanks very much to both of you. Any ideas about the LF end of carriage problem ?
April 13, 201213 yr When exporting data (suit the Export script step) there is an option to choose Macintosh or Windows format.
Create an account or sign in to comment