Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 Want to get only the lower case string value

Author  Topic 

kalyan.cse05
Yak Posting Veteran

74 Posts

Posted - 2012-04-13 : 05:11:10
In my table one column contains two string value.. one is "Test" and another is "test".
I want to get only the the value stats with lower case i.e "test"..
Can someone plz help me?
assume table name is "Kalyan"

kalyan Ashis Dey

sunitabeck
Master Smack Fu Yak Hacker

5155 Posts

Posted - 2012-04-13 : 05:37:50
You can force the comparison in the where clause to use a case sensitive collation - for exampe:
SELECT * 
FROM YourTable
WHERE YourColumn = 'test' COLLATE Latin1_General_CS_AS
Go to Top of Page

kalyan.cse05
Yak Posting Veteran

74 Posts

Posted - 2012-04-13 : 06:43:33
Thanks A lot :)

kalyan Ashis Dey
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2012-04-13 : 11:15:48
other ways are either to use BINARY_CHEKSUM or converting to binary

see

http://vyaskn.tripod.com/case_sensitive_search_in_sql_server.htm

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page
   

- Advertisement -