By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,322 Members | 1,182 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,322 IT Pros & Developers. It's quick & easy.

Problems querying oracle db from Access 2000

P: n/a

I am trying to query a table in oracle from Access 2000 using the
following criteria.

select * from table1 where DATE_RECEIVED between '1/jan/2003' and
'30/jun/2003'

I am using the Oracle odbc driver.

Records should be returned but nothing.

I have tried using different formats, but nothing works.

I am new to Oracle and need some assistance on this small issue.

Any help is appreciated.

Thanks,

Johann

--
Posted via http://dbforums.com
Jul 19 '05 #1
Share this Question
Share on Google+
3 Replies


P: n/a
Hi Jhweb

Try this
select * from table1
where
DATE_RECEIVED
between to_date('1/jan/2003','dd-mon-yyyy') and
to_date('30/jun/2003','dd-mon-yyyy')
regards
Hrishy

P.S:If now roes are returned then run the query in sql plus and see
what is happening..If there is a mismtach the odbc driver is doin
somethin funny
Jul 19 '05 #2

P: n/a
Hi,

little correction inside.
I point it out because Johann wrote that
he's new to the Oracle world.

"hrishy" <hr*****@yahoo.co.uk> schrieb im Newsbeitrag
news:4e**************************@posting.google.c om...
Hi Jhweb

Try this
select * from table1
where
DATE_RECEIVED
between to_date('1/jan/2003','dd-mon-yyyy') and
between to_date('1/jan/2003','dd/mon/yyyy') and
to_date('30/jun/2003','dd-mon-yyyy')
to_date('30/jun/2003','dd/mon/yyyy')


regards
Hrishy

P.S:If now roes are returned then run the query in sql plus and see
what is happening..If there is a mismtach the odbc driver is doin
somethin funny


Greetings,
Guido
Jul 19 '05 #3

P: n/a
jhweb <me*********@dbforums.com> wrote in message news:<32****************@dbforums.com>...
I am trying to query a table in oracle from Access 2000 using the
following criteria.

select * from table1 where DATE_RECEIVED between '1/jan/2003' and
'30/jun/2003'

I am using the Oracle odbc driver.

Records should be returned but nothing.

I have tried using different formats, but nothing works.

I am new to Oracle and need some assistance on this small issue.

Any help is appreciated.

Thanks,

Johann


You could do what Guido is saying there, but by nature of the ODBC
from Access to Oracle, you should just type in the date format the way
Access normally takes it. Access will format the date to it's liking,
but when it is sent through the ODBC driver to Oracle the date will be
converted to the Oracle date format. FYI...the Oracle date formate is
'04-AUG-03 12:00:00 AM' for today.

Oracle does it's date format as date / time. It's confusing for new
users...I was in your shoes a little over a year ago.

http://sqlzoo.net/howto/oracletip70465.htm
Jul 19 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.