Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase «««1234»»

Table Alias Expand / Collapse
Author
Message
Posted Thursday, May 2, 2013 9:16 AM


SSCarpal Tunnel

SSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal Tunnel

Group: General Forum Members
Last Login: Today @ 2:07 PM
Points: 4,043, Visits: 5,361
Interesting back-to-basics question, thanks

____________________________________________
Space, the final frontier? not any more...
All limits henceforth are self-imposed.
“libera tute vulgaris ex”
Post #1448855
Posted Thursday, May 2, 2013 10:02 AM
Old Hand

Old HandOld HandOld HandOld HandOld HandOld HandOld HandOld Hand

Group: General Forum Members
Last Login: Thursday, October 9, 2014 10:54 AM
Points: 319, Visits: 699
Thanks for the easy question.

-Tracie
Post #1448886
Posted Thursday, May 2, 2013 10:32 AM


SSCarpal Tunnel

SSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal TunnelSSCarpal Tunnel

Group: General Forum Members
Last Login: Friday, October 24, 2014 12:43 PM
Points: 4,126, Visits: 3,428
Really nice one - thanks!
Post #1448906
Posted Thursday, May 2, 2013 11:08 AM


SSCoach

SSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoach

Group: General Forum Members
Last Login: Today @ 5:51 PM
Points: 17,845, Visits: 15,797
EZ PZ Lemon Squeezy



Jason AKA CirqueDeSQLeil
I have given a name to my pain...
MCM SQL Server, MVP


SQL RNNR

Posting Performance Based Questions - Gail Shaw
Post #1448926
Posted Thursday, May 2, 2013 2:55 PM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 3:10 PM
Points: 7,814, Visits: 9,563
Hugo Kornelis (5/2/2013)
(And I think every development server SHOULD be set up with case sensitive collation - developing there and deploying to a case insensitive server is okay, the other word around is a disaster

I think I'll add that one to my list of dangerous T-SQL myths. If someone has used a case-sensitive server for development and distinguished betwen the 8 columns COL, COl, CoL, Col, cOL, cOl, coL,and col deployment to a case-insensitive server will be a disaster, far from OK. I am sure that you know better Hugo, and don't understand why you make such a silly statement.

Personally, I think using a case insensitive collation as the default is best practise. Obviously case sensitivity is required for comparing strings in some rare cases, but there's nothing wrong with specifying a case sensitive coolation in those rare cases; the cases where string comparison needs to be case insensitive are, I believe, far more frequent.


Tom
Post #1448985
Posted Thursday, May 2, 2013 2:58 PM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 3:10 PM
Points: 7,814, Visits: 9,563
Hugo Kornelis (5/2/2013)
Rune Bivrin (5/2/2013)
Hugo Kornelis (5/2/2013)

However, to do some nitpicking:

1. If I were to try this code on my system, I would get five errors. All system table (*) names are completely lowercase, so everyone who has a server set up with a case sensitive collation will get error messages. (And I think every development server SHOULD be set up with case sensitive collation - developing there and deploying to a case insensitive server is okay, the other word around is a disaster)

Not necessarily true. If your development server is case sensitive you run the risk of having more than one object with the same name, only with different casing. When deploying on a case INsensitive server it will blow up.

Technically true. Realistically, the chance of this happening by accident is a lot smaller than the chance of using wrong case on a case insensitive server.

If something is case insensitive there is no possible real world referent for "wrong case". So how is the chance of using the "wrong case" different from zero?


Tom
Post #1448986
Posted Thursday, May 2, 2013 3:37 PM
SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Today @ 5:17 PM
Points: 2,418, Visits: 1,501
+1

Not all gray hairs are Dinosaurs!
Post #1448998
Posted Thursday, May 2, 2013 4:42 PM


SSC-Dedicated

SSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-DedicatedSSC-Dedicated

Group: General Forum Members
Last Login: Today @ 10:15 PM
Points: 35,399, Visits: 31,959
L' Eomot Inversé (5/2/2013)
Hugo Kornelis (5/2/2013)
(And I think every development server SHOULD be set up with case sensitive collation - developing there and deploying to a case insensitive server is okay, the other word around is a disaster

I think I'll add that one to my list of dangerous T-SQL myths. If someone has used a case-sensitive server for development and distinguished betwen the 8 columns COL, COl, CoL, Col, cOL, cOl, coL,and col deployment to a case-insensitive server will be a disaster, far from OK. I am sure that you know better Hugo, and don't understand why you make such a silly statement.

Personally, I think using a case insensitive collation as the default is best practise. Obviously case sensitivity is required for comparing strings in some rare cases, but there's nothing wrong with specifying a case sensitive coolation in those rare cases; the cases where string comparison needs to be case insensitive are, I believe, far more frequent.


+1000. Becoming a slave to case sensitivity is a bit insane especially since MS itself has NOT adopted a reasonable naming convention for any objects be it a table name, a column name, or what have you. There are actually very few things that need to be case sensitive. Isolate those things at table design time and make only those columns case senstive. The fact that things like Intellisense perpetuate the poor casing is no good reason for having a case senstive server.


--Jeff Moden
"RBAR is pronounced "ree-bar" and is a "Modenism" for "Row-By-Agonizing-Row".

First step towards the paradigm shift of writing Set Based code:
Stop thinking about what you want to do to a row... think, instead, of what you want to do to a column."

(play on words) "Just because you CAN do something in T-SQL, doesn't mean you SHOULDN'T." --22 Aug 2013

Helpful Links:
How to post code problems
How to post performance problems
Post #1449010
Posted Friday, May 3, 2013 6:55 AM


Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Tuesday, September 30, 2014 7:42 AM
Points: 3,688, Visits: 72,435
Nice question on the fundamentals... thanks for it.



--Mark Tassin
MCITP - SQL Server DBA
Proud member of the Anti-RBAR alliance.
For help with Performance click this link
For tips on how to post your problems
Post #1449178
Posted Friday, May 3, 2013 8:03 AM


Hall of Fame

Hall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of FameHall of Fame

Group: General Forum Members
Last Login: Today @ 4:42 PM
Points: 3,366, Visits: 2,005
Thanks for the easy question! Good back to basics one.
Post #1449218
« Prev Topic | Next Topic »

Add to briefcase «««1234»»

Permissions Expand / Collapse