Viewing 15 posts - 35,596 through 35,610 (of 49,557 total)
RGDavis396 (11/30/2009)
Searches against string values tend to be slower than those against numerical values
Have you tested against large volumes of data under load? If so, are you seeing a measurable,...
November 30, 2009 at 8:09 am
--check if record already exists.
IF NOT EXISTS (SELECT ID FROM TableOne WHERE Col1 = @var1 )
BEGIN
IF @var2 = 1
...
November 30, 2009 at 7:35 am
GSquared (11/30/2009)
November 30, 2009 at 7:33 am
Piotr.Rodak (11/30/2009)
Well, if the database is offline you can't connect to it, so why would you want to write anything to it?
The insert is in the ELSE portion, ie...
November 30, 2009 at 7:24 am
Give us some background on what happened before this error appeared.
Is the log file there? If not, do you know what happened to it?
November 30, 2009 at 6:43 am
You're overcomplicating things. No need for the SELECT in that case. You don't need to assign to a separate variable, unless you're going to use that second variable later
DECLARE @DocIDOne...
November 30, 2009 at 6:42 am
manikandan.chokkalingam (11/30/2009)
i have three text boxes
Doesn't sound like SQL to me. SQL has no text boxes. Maybe you can give us some more information, including where these 'text boxes' appear....
November 30, 2009 at 5:36 am
No such thing as a GET in SQL. I think you need to take several steps back and explain what it is that you're trying to achieve here.
The syntax...
November 30, 2009 at 3:42 am
Please post table definitions, sample data and desired output. Read this to see the best way to post this to get quick responses.
http://www.sqlservercentral.com/articles/Best+Practices/61537/
November 30, 2009 at 3:20 am
The insert statement right before the second fetch is only half-done. You need to define what to insert (either a VALUES clause or a SELECT statement)
Why a cursor? From the...
November 30, 2009 at 3:20 am
Stay away from cursors. They have their place (rarely) but they should not be used when there's a simple set-based alternative, as there is here.
Are you trying to learn SQL...
November 30, 2009 at 3:14 am
winston Smith (11/24/2009)
1. what can cause a checkpoint spid to hang
Counter question. How did you determine that the checkpoint had hung?
if i done this in production, would it corrupt data...
November 30, 2009 at 3:03 am
Couple questions.
Why do you want to do this with a cursor when a single update statement will do the job perfectly well?
Why are you denormalising the database? How are you...
November 30, 2009 at 2:55 am
For a good introduction to triggers in SQL, please read this: http://www.sqlservercentral.com/articles/Triggers/64214/
I also have to ask, why do you want to do this? Storing redundant data is usually a bad...
November 30, 2009 at 2:53 am
As I said, escape a quote by doubling it. So if you want single quotes within a string, put two of them to make a single ' character.
November 30, 2009 at 1:25 am
Viewing 15 posts - 35,596 through 35,610 (of 49,557 total)