Getting incorrect datetime from Oracle Query

Hello All,

I am using the following SQL in the Database Reader node with Oracle:
SELECT
TO_DATE(SYSDATE, ‘yyyy-mm-dd HH24:mi:ss’) “NOW”
FROM DUAL

The result contains the correct Date but the time is always 00:00:00.

This query works in Oracle Workbench. I am not sure why it is not working in Knime

Any ideas?

Maybe Workbench is wrong? Oracle’s LiveSQL ( https://livesql.oracle.com/ ) returns a TO_DATE as indeed a date without a calculated time of day attached (as the docs seem to imply https://docs.oracle.com/cd/B19306_01/server.102/b14200/functions183.htm ), using TO_CHAR returns a string representing the format specified.

@quaeler, you have to set the NLS_DATE_FORMAT with LiveSQL. For e.g. see:

57%20PM

Ah - good to know. Sorry for the red herring.