Thursday, March 02, 2006

The Terminator;

SQL Server 2005 - big changes - little changes. One of the little changes that's been a big change getting used to is the statement terminator, the semicolon. I've been forcing myself to place semicolons after every statement in my code, and going back through old code and adding the semicolons. They say that 21 days with a new behavior creates a habit. Maybe;

I have learned a few things about statement terminators;

1) You must place a semicolon at the end of the statement before a Common Table Element (CTE), otherwise the parser doesn’t know the WITH is starting a CTE and the batch will blow up like a bad action movie pun;

2) You can not place a statement terminator after the IF condition. Just treat the IF Condition -Next Statement as one long continuous statement;

3) You can not place a statement terminator between a END TRY and a BEGIN CATCH. Those two statements seem function as one single statement;

Right now statement terminators are optional, will they become required, maybe. I hear that one reason we don't have intellisense is that it's difficult to parse half written T-SQL without a statement terminator. Given the choice - I'd take required semicolons if that means we get intellisense;

I'll be back;


At 4:18 PM, Blogger louissmith1247712484 said...

Are you stuck in a job that is leading you on the path to no where?
We can help you obtain a College Degree with classes, books, and exams
Get a Genuine College Degree in 2 Weeks!
Well now you can get them!

Call this number now 24 hours a day 7 days a week (413) 208-3069

Get these Degrees NOW!!!


Within 2 weeks!
No Study Required!
100% Verifiable

Call this number now 24 hours a day 7 days a week (413) 208-3069

These are real, genuine, They are verifiable and student records and
transcripts are also available. This little known secret has been
kept quiet for years. The opportunity exists due to a legal loophole
allowing some established colleges to award degrees at their discretion.

With all of the attention that this news has been generating, I wouldn't
be surprised to see this loophole closed very soon

Get yours now, you will thank me later
Call this number now (413) 208-3069
We accept calls 24 hours a day 7 days a week.


Post a Comment

<< Home