Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
btrompetter
Contributor III
Contributor III

Oracle -> WHERE Clause -> Date Question

Hello,

I want to query a table in QlikView with the following SQL Statement over an OLEDB Oracle connection:

SQL SELECT *
FROM "GLB_RPT"."SALES_TAG_SOR"
WHERE "SALES_TAG_SOR"."DATUM" >= '01.03.2009';

But I got all records.

How must the statement look like? Must I use to_date?

Thanks for help

Bastian

1 Solution

Accepted Solutions
btrompetter
Contributor III
Contributor III
Author

If I change it to

SQL SELECT *
FROM "GLB_RPT"."SALES_TAG_SOR"
where (DATUM) >= (to_date('01.03.2009','DD.MM.YYYY'));

it works

regards

Bastian

View solution in original post

3 Replies
Not applicable

Bastian,

What is the native date format of DATUM in the database?

Reagrds,

Gordon

btrompetter
Contributor III
Contributor III
Author

If I change it to

SQL SELECT *
FROM "GLB_RPT"."SALES_TAG_SOR"
where (DATUM) >= (to_date('01.03.2009','DD.MM.YYYY'));

it works

regards

Bastian

Anonymous
Not applicable

Bastian,

The safe way to get rid of this sort of problems is to use the preceeding load:


LOAD
...
WHERE "SALES_TAG_SOR"."DATUM" >= '01.03.2009' // if this is your format in QV
SQL SELECT *
FROM "GLB_RPT"."SALES_TAG_SOR";


Regards,
Michael