Skip to Main Content

SQL Developer

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!

encounter error PLS-00382: expression is of wrong type

xrys9023720Mar 2 2012 — edited Mar 2 2012
Hi -

Can someone please help me? I've created a function and was trying to compile this:

FUNCTION val_star_item (i_segment1 IN VARCHAR2,
i_description IN VARCHAR2)
RETURN BOOLEAN
IS
v_star BOOLEAN;

BEGIN
IF i_segment1 = i_description THEN
return('Y');
ELSE
return('N');
END IF;
END val_star_item;

But I've encountered this error:

LINE/COL ERROR
-------- -----------------------------------------------------------------
322/9 PL/SQL: Statement ignored
322/15 PLS-00382: expression is of wrong type
324/11 PL/SQL: Statement ignored
324/17 PLS-00382: expression is of wrong type
Input truncated to 1 characters

And it's referring I think to this part of my code: i_segment1=i_description. My objective here is to compare what ever value I had for those parameters. If both are the same then return Y if not then return N.

Thank you
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 30 2012
Added on Mar 2 2012
2 comments
689 views