Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Issue with not equal to empty condition

761447Jul 5 2010 — edited Jul 5 2010
Hi Friends,

I'm new to oracle. I have a IF condition that checks if the variable is not equal to empty. But the condition fails even if the variable has its value. I have added the part of the code below.
 v_MyTestVar := 'Success!' ;

 IF v_MyTestVar <> '' THEN
   DBMS_OUTPUT.PUT_LINE('v_MyTestVar IS NOT EQUAL TO NULL');
 END IF;
Please anyone help me with the solution for this problem.

Thanks,
Ram
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 2 2010
Added on Jul 5 2010
5 comments
2,225 views