Trying to add a date parameter to a reader's source URL in the mm/dd/yyyy format for today's date
Page 1 / 1
Try:
@DateTimeFormat($(MyDateParameter),%m/%d/%Y)
See FME Date/Time Functions help for further reference:
Try:
@DateTimeFormat($(MyDateParameter),%m/%d/%Y)
See FME Date/Time Functions help for further reference:
Just re-read the bit about this being today's date. You strictly speaking don't need a Parameter to do this for the Reader Source string. The above formula could be rewritten as:
@DateTimeFormat(@DateTimeNow,%m/%d/%Y)
So the Source URL can be written to be evaluated as:
http://mywebdatasource.com/date@DateTimeFormat(@DateTimeNow,%m/%d/%Y)
Or whatever URL string parsing is required.
An alternative is to replace the reader with a FeatureReader transformer. You can then start the workspace with a Creator and follow up with a DateTimeStamper (and DateTimeConverter, if necessary) before passing it on to the FeatureReader as a part of the URL.