Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> variable column query in cursor?

variable column query in cursor?

From: R. Burton <rburton_at_rohms.com>
Date: 1997/06/05
Message-ID: <3397021B.3465@rohms.com>#1/1

I'm wondering if anyone can tell me why this does not work:

    cursor	SONGS (scol varchar2, searchval varchar2) is
			select * from ss1 where scol like searchval ;

if I call SONGS with the column name specified, it won't work; it works with searchval.

What are the appropriate work-arounds? Obviously, I'd like to have a single cursor defined which allows me to specify both the search text as well as the column to search on.

Please e-mail: rburton_at_rohms.com Thanks! Received on Thu Jun 05 1997 - 00:00:00 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US