About
Pricing
Community
Teams
Start Free Trial
Log in
Ricky White
asked on
7/3/2012
Assistance with Sql server query uppercase?
Environment: Sql Server 2000
State:
California
WASHINGTON
UTAH
I have a SQL table and would like to search for all state's that are fully in uppercase.
My Sql query is
Select * from temp
where state = uppercase states
expected results:
WASHINGTON
UTAH
Please advise. how can this be achieved?
Thanks!
Microsoft SQL Server
Microsoft SQL Server 2005
SQL
4
2
Last Comment
Ricky White
8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
Ron Malmstead
7/3/2012
THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
SOLUTION
Brendt Hess
7/3/2012
THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
keyu
7/3/2012
declare @statelist as varchar(max)
select @statelist=coalesce(@state
list,',')+
state from table_name where state=upper(state)
select @statelist
Ricky White
7/4/2012
ASKER
Thanks!
I started with Experts Exchange in 2004 and it's been a mainstay of my professional computing life since. It helped me launch a career as a programmer / Oracle data analyst
William Peck
select @statelist=coalesce(@state
select @statelist