Toad World® Forums

Toad for DA 2.5 - Date comparisons and conversions


#1

Hi,

I have an odbc connection from Toad DA to an Oracle Bi server. I am trying to do a simple query : query a table where “Birth Date” > ‘01/16/1957’

In the target BI server, 'Birth Date" is varchar2, and hence it returns values 01/19/1964, 01/24/1935… 01/24/1935 should not be returned.

How can I use a date function to compare like I would normally do :

select *
from …
where to_date(“Birth Date”, ‘mm/dd/yyyy’) > to_date(‘01/16/1957’, ‘mm/dd/yyyy’)
The above results in sql syntax error.

Any help would be appreciated!

Thanks!


#2

You would need to look into what functions the driver supports.

Debbie


#3

I’m not sure if the text you pasted is actual or a typo but it looks like you have quotes around the Birth_Date field.