{"id":615,"date":"2015-06-10T14:17:39","date_gmt":"2015-06-10T08:47:39","guid":{"rendered":"http:\/\/pramodsingla.com\/?p=615"},"modified":"2015-06-10T14:17:39","modified_gmt":"2015-06-10T08:47:39","slug":"sql-server-check-whether-the-sql-server-is-configured-for-case-sensitivity-or-not","status":"publish","type":"post","link":"https:\/\/pramodsingla.com\/?p=615","title":{"rendered":"SQL Server &#8211; Check whether the SQL server is configured for case sensitivity or not"},"content":{"rendered":"<p><span style=\"color:#ff0000;\"><strong>Problem: <\/strong><\/span>How to check whether the SQL\u00a0server is configured for case\u00a0sensitivity\u00a0or not?<\/p>\n<p style=\"text-align:justify;\"><span style=\"color:#008000;\"><strong>Solution:<\/strong><\/span><\/p>\n<ul style=\"text-align:justify;\">\n<li><span style=\"color:#000000;\"><strong><em>Case sensitivity:<\/em><\/strong> By Case Sensitive, we mean case sensitivity of the objects in the database, i.e. the following two statements are not equal:-<\/span><\/li>\n<\/ul>\n<p style=\"text-align:justify;padding-left:60px;\">SELECT * FROM TABLE<\/p>\n<p style=\"text-align:justify;padding-left:60px;\">SELECT * FROM table<strong>\u00a0<\/strong><\/p>\n<ul>\n<li style=\"text-align:justify;\">SQL server determines case sensitivity by <span style=\"color:#0000ff;\"><strong>COLLATION<\/strong><\/span>.<\/li>\n<\/ul>\n<ul>\n<li style=\"text-align:justify;\"><em><strong>Collation<\/strong>:\u00a0<\/em><span style=\"color:#ff0000;\"><span style=\"color:#000000;\">Collation refers to a set of rules that determine how data is sorted and compared. Character data is sorted using rules that define the correct character sequence, with options for specifying case-sensitivity, accent marks, kana character types and character width.<\/span><\/span><\/li>\n<\/ul>\n<ul>\n<li style=\"text-align:justify;\">COLLATION can be set at various levels:-<\/li>\n<\/ul>\n<p style=\"text-align:justify;padding-left:60px;\">1.\u00a0Server-level<br \/>\n2. Database-level<br \/>\n3. Column-level<br \/>\n4. Expression-level<\/p>\n<ul style=\"text-align:justify;\">\n<li>Check Database Collation:-<\/li>\n<\/ul>\n<blockquote>\n<p style=\"text-align:justify;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 <strong>SELECT DATABASEPROPERTYEX (&#8221;, &#8216;Collation&#8217;)<\/strong><\/p>\n<\/blockquote>\n<p style=\"text-align:justify;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 Result: SQL_Latin1_General_CP1_<strong>CI<\/strong>_AS (means Case Insensitive)<\/p>\n<p style=\"text-align:justify;\">\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 Result: SQL_Latin1_General_CP1_<strong>CS<\/strong>_AS (means Case Sensitive)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Problem: How to check whether the SQL\u00a0server is configured for case\u00a0sensitivity\u00a0or not? Solution: Case sensitivity: By Case Sensitive, we mean[&#8230;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_mi_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0},"categories":[1],"tags":[],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/pramodsingla.com\/index.php?rest_route=\/wp\/v2\/posts\/615"}],"collection":[{"href":"https:\/\/pramodsingla.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pramodsingla.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pramodsingla.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/pramodsingla.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=615"}],"version-history":[{"count":0,"href":"https:\/\/pramodsingla.com\/index.php?rest_route=\/wp\/v2\/posts\/615\/revisions"}],"wp:attachment":[{"href":"https:\/\/pramodsingla.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=615"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pramodsingla.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=615"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pramodsingla.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=615"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}