Home » SQL & PL/SQL » SQL & PL/SQL » NULLIF (Oracle 9i)
NULLIF [message #399557] Thu, 23 April 2009 00:21 Go to next message
Messages: 262
Registered: December 2008
Location: Hyderabad
Senior Member

SQL>SELECT NULLIF(comm,NULL) from emp;






14 rows selected.

SQL> select NULLIF(NULL,comm) from emp
ERROR at line 1:
ORA-00932: inconsistent datatypes: expected - got CHAR

Why it's returning error.
Re: NULLIF [message #399567 is a reply to message #399557] Thu, 23 April 2009 00:48 Go to previous message
Michel Cadot
Messages: 64103
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
A useful link for you: SQL Reference.

Please read OraFAQ Forum Guide, especially "How to format your post?" section.
Make sure that lines of code do not exceed 80 characters when you format.
Indent the code (See SQL Formatter), use code tags and align the columns in result.
Use the "Preview Message" button to verify.
Also always post your Oracle version (4 decimals).

Previous Topic: partition by rownum - clarify
Next Topic: Database Link Insert with Function
Goto Forum:

Current Time: Sun Dec 04 21:03:34 CST 2016

Total time taken to generate the page: 0.05548 seconds