Skip to main content
Solved

Date Conversion from EXIFF format

  • July 16, 2020
  • 3 replies
  • 139 views

Hi Guys, I am reading in JPG's and writing to a TAB file with attributes.

I want to convert the EXIFF date format to DD/MM/YYYY with time if possible.

The format EXIFF provides is YYYY:MM:DD HH:MM:SS eg 2020:06:03 08:55:21

Can this be done in the feature writer? eg changing the value with a @Value(jpeg_exif_datetime,%d/%m/%Y) command is this the right approach?

Dave

 

 

 

 

 

 

Best answer by ebygomm

If you want to write the date into a field of type date in your mapinfo TAB file, you will want to convert it to FME format YYYYMMDD, display as DD/MM/YYYY  should be handled wherever the data is viewed.

I would use a DateTimeConverter prior to the FeatureWriter, the EXIF format is available to select as an Input Format

%Y:%m:%d %H:%M:%S$
This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

3 replies

redgeographics
Celebrity
Forum|alt.badge.img+59
  • Celebrity
  • 3700 replies
  • July 16, 2020

There is a @DateTimeFormat function that you can use but it expects the input to be in FME DateTime format, which the EXIF isn't. A DateTimeFormatter transformer should do the trick, you'll probably have to specify the input format to be on the safe side.


ebygomm
Influencer
Forum|alt.badge.img+44
  • Influencer
  • 3427 replies
  • Best Answer
  • July 16, 2020

If you want to write the date into a field of type date in your mapinfo TAB file, you will want to convert it to FME format YYYYMMDD, display as DD/MM/YYYY  should be handled wherever the data is viewed.

I would use a DateTimeConverter prior to the FeatureWriter, the EXIF format is available to select as an Input Format

%Y:%m:%d %H:%M:%S$

Excellent, thankyou!