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 Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Uppercase PROMPT value in SQLPlus? Possible? 2

Status
Not open for further replies.

MCubitt

Programmer
Mar 14, 2002
1,081
GB
Rather than use
upper(&value)
throughout an SQL statement for a PROMPTed value, is there a way to change it once?

I.e.

prompt Enter value: &&value
newvalue = upper(&value)

select * from table where column1=newvalue or column7=newvalue


Thanks

(In SQLPlus, not PL/SQL)



There's no need for sarcastic replies, we've not all been this sad for that long!
 
You may declare bind variable and then use it:

SET FEEDBACK OFF
var uValue VARCHAR2(256)
EXEC :uValue := UPPER('&value')


select :uValue from dual

Regards, Dima
 
Bravo! Thank U!


There's no need for sarcastic replies, we've not all been this sad for that long!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top