Skip to main content

Hello,

I would like to pass date/time user parameter (Date Ranges)
to a SQL-Non Spatial reader where clause. I have tried the following with no
success.

[wo_complete_dt]>= {ts
$(DateRangeStart)} AND [wo_complete_dt]< {ts $(DateRangeEnd)}

[wo_complete_dt]>= {ts ‘$(DateRangeStart)’}
AND Awo_complete_dt]< {ts ‘$(DateRangeEnd)’}

}wo_complete_dt]>=
'$(DateRangeStart)' AND 3wo_complete_dt]<'$(DateRangeEnd)'

;wo_complete_dt]>=
$(DateRangeStart) AND rwo_complete_dt]< $(DateRangeEnd)

However, if I change the user parameter to a text type or input
the dates directly into the Where clause as shown here it does work.

wo_complete_dt]>={ts
'2019-06-09 00:00:00'} AND 9wo_complete_dt]<{ts '2019-06-16 00:00:00'}

 

Can someone please guide me?

Using FME Desktop 2019.

Thanks in advance,

Keith

The date/time user parameter stores the date in FME format, i.e. 20190609000000, although it is displayed as 2019-06-09 00:00:00

You will need to convert the date to the format you need for your sql statement. This can be done in the statement itself.

 


Reply