Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Oracle driver issue

Status
Not open for further replies.

APB1981

Technical User
Jul 10, 2005
83
NO
Hello,

version Oracle 9.2
Crystal reports XI

I am having a small oracle issue. I want to use the standard "Oracle server" driver but it does not allow me to create an sql expression IFNULL:

{fn IFNULL("Table"."field", 0)}

Does anyone have ideas.

I then place this sql expression into my record selection:

{%SQL expression} = 0

I could use a formula but then it will be much slower and the statement will not be passed to the SQL "Where" section.


If I use the Oraoledb.oracle driver then it works but I am getting the following error when I run the report in my application: database vendor code: 942

Thanks in advance..

AB



APB
 
Hi,
Oracle does not support the use of
{fn IFNULL("Table"."field", 0)}
( it is not a 'native' Oracle syntax or function.).

Look at Oracle's NVL function...

NVL("Table"."field", 0)




[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
Hi,
Also , it has nothing to do with the driver used...

The error you received is unrelated to the Function you tried to use, it is a 'Table or View does not exist' error..



[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
Thanks for that. The NVL did the trick..

Appreciate it.

APB

APB
 
I believe if you just use:

isnull({table.field})

...in the record selection formula that it will pass to the SQL query.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top