Viewing 15 posts - 19,201 through 19,215 (of 22,202 total)
I'd suggest using the TOP and an ORDER BY within the sub-query instead. Assuming there is an index for the ORDER BY clause to use, I think you'll see better...
December 1, 2008 at 7:01 am
As everyone else has said, it depends.
I used to use the approach of an identity column on most, if not all, tables. I've learned better. Now I tend towards what...
December 1, 2008 at 6:54 am
The way I've done it previously is to output the procedure to XML and store it on the side. Then as you make adjustements to the query, you can compare...
December 1, 2008 at 6:45 am
Oops. Missed that this was SQLCMD
That's OK. You can use SQLCMD variables the same way, still using OUTPUT parameters. For more on SQL Command variables, this is BOL: ms-help://MS.SQLCC.v10/MS.SQLSVR.v10.en/s10de_1devconc/html/793495ca-cfc9-498d-8276-c44a5d09a92c.htm
Or online...
December 1, 2008 at 6:37 am
Use output parameters. They work a little like this:
--create a procedure
CREATE PROCEDURE dbo.MyProc
@ID int OUTPUT
AS
SELECT ID FROM schema.Table
GO
--now you can call the proc like this
DECLARE @LocalId int
EXEC dbo.MyProc @ID =...
December 1, 2008 at 6:33 am
I think you've hit the nail on the head here Tony. I don't agree with either of the wild fringe groups. I think that well designed apps take advantage of...
December 1, 2008 at 6:16 am
Permits? We don't need no stinking permits.
Seriously though, the main reason I keep coming back here, well, in addition to learning something every single day, is that the tone is...
December 1, 2008 at 5:50 am
Well, it was a thrilling moment, I don't mind saying. I'll be picking up one of those integrated face sheild/helmet/ear protection things soon (read ASAP). First time in 10 years...
November 30, 2008 at 8:08 am
I'm sort of loving the long weekend. I'm busting butt on the stupid book and I'm chain-sawing & splitting wood to get ready for the winter.
Broke a chain for...
November 30, 2008 at 7:12 am
rbarryyoung (11/29/2008)
Lynn Pettis (11/29/2008)
I just find it pretentious to list all those certs. It begs the question, who is he trying to impress.
Probably himself. Seriously. It's easy...
November 30, 2008 at 7:03 am
rbarryyoung (11/28/2008)
November 28, 2008 at 2:31 pm
May as well chime in on this one.
First off, Phil, feel lucky. At least your developers are still at least using the words "data." We've had a rash of the...
November 28, 2008 at 6:54 am
Yikes! I'd say so. Upgrades to the data model must be entertaining.
November 28, 2008 at 6:28 am
GilaMonster (11/27/2008)
Train wreck waiting to happen.
If you want some...
November 27, 2008 at 8:27 am
J (11/27/2008)
Could you not just use a common table with an extra field like "OwnerID"to keep...
November 27, 2008 at 8:21 am
Viewing 15 posts - 19,201 through 19,215 (of 22,202 total)