Viewing 15 posts - 12,826 through 12,840 (of 26,486 total)
Kausar Mehmood (4/16/2012)
April 16, 2012 at 12:31 pm
Depends, what is the purpose of this exercise? Is this for a class project?
April 16, 2012 at 12:28 pm
Welsh Corgi (4/16/2012)
Lynn,It works, my vision must be failing me because I did not notice the difference?
Thanks!
Glad to help.
Think of it as a stored procedure that you need to return...
April 16, 2012 at 12:24 pm
Welsh Corgi (4/16/2012)
SET @SQLQuery = 'SELECT COUNT(*) FROM ' + @SchemaName +'.'+ @SQLTableName
DECLARE @MyCnt INT;
DECLARE @ParmDefinition...
April 16, 2012 at 12:16 pm
SQLCrazyCertified (4/16/2012)
jralston88 (4/13/2012)
We want to test our restore process for each database. Since we don't want to test on...
April 16, 2012 at 12:09 pm
Larry Page(Ehsan.Akbar) (4/16/2012)
SQLKnowItAll (4/16/2012)
Lynn Pettis (4/16/2012)
SQLKnowItAll (4/16/2012)
April 16, 2012 at 12:06 pm
Here is a quick sample you can run:
CREATE TABLE #TestIt(TabID INT);
INSERT INTO #TestIT
SELECT 1 UNION ALL SELECT 2 UNION ALL SELECT 3;
DECLARE @MyCnt INT;
DECLARE @SQLCmd NVARCHAR(MAX);
DECLARE @ParmDefinition nvarchar(500);
SET @SQLCmd =...
April 16, 2012 at 11:58 am
SQLKnowItAll (4/16/2012)
April 16, 2012 at 11:47 am
You need to declare the variable in the dynamic sql, set it to count(*) in your select. The output variable used in the sp_executesql proc will then have that...
April 16, 2012 at 11:41 am
Sean Lange (4/16/2012)
hbtkp (4/16/2012)
OK SORRY MAX date its working.help me with cumulative calculation
Help us help you by posting details.
Help us help you by posting details.
Help us help you by...
April 16, 2012 at 11:30 am
hbtkp (4/16/2012)
OK SORRY MAX date its working.help me with cumulative calculation
How are we supposed to help? You won't give us anything to work with to help you. ...
April 16, 2012 at 11:28 am
GilaMonster (4/16/2012)
This is one area where I and many others disagree with Book Online. Set the max server memory always. See chapter 4 of the book I linked to.
And I...
April 16, 2012 at 11:01 am
donato1026 (4/16/2012)
Lynn Pettis (4/16/2012)
Missing a comma! ...
And this is when I go outside and walk in front of oncoming traffic... If I may, I would like to use the fact...
April 16, 2012 at 10:57 am
Missing a comma!
DECLARE Contacts CURSOR LOCAL FAST_FORWARD READ_ONLY FOR
SELECT
distinct(CUST_CD)
,TRK_NUM
,EMAIL_ADDR
,DELIVERY_DATE
...
April 16, 2012 at 10:47 am
capn.hector (4/16/2012)
Phil Parkin (4/16/2012)
Actually the statement previous to the WITH (CTE) needs to be terminated with a semi-colon.
Grrrr! Correct 🙂
when posting code i always put the semi colon infront of...
April 16, 2012 at 10:40 am
Viewing 15 posts - 12,826 through 12,840 (of 26,486 total)