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

Uppercase SQL

Status
Not open for further replies.

TJP212

IS-IT--Management
Mar 12, 2008
2
US
I am new to SQL and not sure if i am going in the right direction to perform what i want to do. What i want to do is covert a column name "DESC_RT_LINE" to uppercase in a table named "ROUTER_LINE"

UPDATE ROUTER_LINE SET ROUTER_LINE.DESC_RT_LINE = (SELECT UCASE (DESC_RT_LINE) FROM ROUTER_LINE)

Right now this is where i am at and it gives an error of
"ODBC Error: SQLSTATE = S1000, Native error code = 0
'Invalid row-count in subquery."

Any Help Please!
 
An easier way of doing it is:
UPDATE ROUTER_LINE SET ROUTER_LINE.DESC_RT_LINE = UPPER(DESC_RT_LINE)

Mirtheil
Certified Pervasive Developer
Certified Pervasive Technician
 
Thanks, did the trick, i knew i was making it harder then it needed to be
Thanks Again
 
Just so you know your sub-select was returning more than one row hence the error.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top