SQL case sensitive queries
-
-
»WHERE username = 'username' COLLATE SQL_Latin1_General_CP1_CS_AS
// Where CS in the end stands for Case Sensitive. If you change it with CI, you'll get Case INsensitive.
»WHERE CAST(username AS varbinary(8)) = CAST('username' AS varbinary(8))
// This works because the binary version of e.g. 'a' isn't equal to 'A'.
Leave a Reply
Welcome to Thronic.com
Search this Site
Miscellaneous Links
Recent Articles
- Google-like search suggestion tool
- Linux Bash Color
- Resize a div layer with javascript
- Moving a div layer with javascript
- Web Galaxy » A sci-fi browser game
- Windows 7 on Asus Eee 900 PC
- IE and PHP sessions
- Wordpress 2.8.6 Spell Check Languages
- Reset MySQL Root Password
- Linux hosts file
- IdleGuard
- Column count in SQL
- String encryption in PHP
- Alphanumeric Captcha values in PHP
- Your own numeric Captcha in PHP
