Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

ORA-00900: invalid SQL statement

Posted on 2007-03-28
2
Medium Priority
?
662 Views
Last Modified: 2013-12-07
Why is this not being excepted?

Select

        *

From

        tmoadm.dat01 d1,

        tmoadm.dat02 d2

Where

       rownum < 15 AND

       d1.LOAN_NUM = d2.LOAN_NUM AND

       (

                          (d2.application_date >= '01/Jan/2007'  And

                          d2.application_date < '02-Jan-2007')

                          OR

                          (d2.FUNDING_AMOUNT >= '01/Jan/2007' And

                          d2.FUNDING_AMOUNT < '02-Jan-2007')

      )
0
Comment
Question by:rufassa
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
2 Comments
 
LVL 20

Accepted Solution

by:
gatorvip earned 375 total points
ID: 18810301
Well, for one, you need to convert your date strings to a valid date format. Use the to_date() function.
0
 
LVL 20

Expert Comment

by:gatorvip
ID: 18810313
Also, are you sure that FUNDING_AMOUNT is really a date as it appears to be in your code? It's misnamed, in that case (imo).
0

Featured Post

Veeam Disaster Recovery in Microsoft Azure

Veeam PN for Microsoft Azure is a FREE solution designed to simplify and automate the setup of a DR site in Microsoft Azure using lightweight software-defined networking. It reduces the complexity of VPN deployments and is designed for businesses of ALL sizes.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you find yourself in this situation “I have used SELECT DISTINCT but I’m getting duplicates” then I'm sorry to say you are using the wrong SQL technique as it only does one thing which is: produces whole rows that are unique. If the results you a…
One of the most important things in an application is the query performance. This article intends to give you good tips to improve the performance of your queries.
Via a live example, show how to take different types of Oracle backups using RMAN.
This video shows how to configure and send email from and Oracle database using both UTL_SMTP and UTL_MAIL, as well as comparing UTL_SMTP to a manual SMTP conversation with a mail server.

604 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question