Toad World® Forums

getting started


#1

Hi

I’m new to SQL Navigator 5.5 and find it quite difficult to get started with the product for Oracle 9i:

Just trying out a simple SQL in a stored procedure the column function substr(…) is recognised as such and appears in bold black type, but not for example dateadd(…):

PL/SQL: ORA-00904: '"DATEADD"invalid identifier.

Why? Dateadd works in SQLPlus. The Help tool is no use as it doesn’t even mention column functions or substr. Where do I get a list of the function set which is available in SQL Navigator ?

Thanks

PS. A tutorial or some examples would be nice!


#2

Hi there! Welcome to the SQL Navigator forum. I hope we can help.

I believe that your problem may be that the DateADD function is a SQL Server function and not an Oracle function. That would explain why you’re getting Oracle error message PL/SQL: ORA-00904: “DATEADD” invalid Identifier. In SQL Navigator, all we’re doing is passing the SQL in the editor to the database and returning the error that the database gives to us. That error message is not coming from SQL Navigator.

If you want to add the DateADD function to your database, I found a script that creates an Oracle equivalent to the SQL Server function here: http://www.databasejournal.com/scripts/article.php/3336941. I tried it and it seems to need a little cleanup before it compiles. I attached a better version to this post for you.

Please let me know if this helps!

Daniel
dateadd.sql (1.83 KB)