3
Answers

Sql query

Vikram Agrawal

Vikram Agrawal

10y
621
1
hello friends,
 
If at all i want to compare values from database without ignoring case then how can i do this in Sql Server?
 
for example :
suppose i have this table
 
TblLogin
UserName Password
user1 Vikram
user2 csharpcorner
user3
microsoft
 
 Select UserName From TblLogin Where Password='vikram'      (here i m passing password in small case but in the table that is in title case)
 
this query will return user1 as result, which is incorrect according to my requirement.
i want to get UserName only when password is in correct case. i.e. 'Vikram'
can you tell me how to write this type of query?

Answers (3)