Forum Replies Created

Viewing 11 posts - 151 through 161 (of 161 total)

  • RE: How to report missing rows too

    Its a bit lengthy but it does work.

    declare @LowerAge int

    declare @UpperAge int

    set @LowerAge = 21

    set @UpperAge = 30

    declare @zerocount table (Age int, Qty int)

    while @LowerAge <= @UpperAge

    begin

    insert into @zerocount (Age,...

  • RE: active/active vs active/passive config

    Having spent some time looking into setting up an Active/Passive cluster I agree with the comments made by bkelley.

    Am I also right in thinking that Active/Passive is normally used to...

  • RE: Tracing Parallel Processing

    Thanks, but neither of these events populate the TextData field of the profiler. I cannot therefore easily identify which of my SPs are most costly.

  • RE: Inserting a single quote using stored procedures

    You should be able to insert a varchar containing a single quote into a table field without any problems. However, if you are concatenating the varchar param into a...

  • RE: referring to added temp table columns in same sp

    Have you tried creating your temp table before you populate it.

    CREATE TABLE #test_temp.......

    INSERT INTO #test_temp (....)

    SELECT .....

    FROM authors

    ALTER TABLE #test_temp ADD mycolumn varchar(50) null

    etc etc....

  • RE: Copy SP using T-SQL

    I presume you are wanting to do this programmatically, since the manual method of scripting the object is straight forward.

    Have you considered creating a DTS package to transfer the SQL...

  • RE: SQL Help

    Is your test data correct.

    10001 is the only cut with all its batches with a value of 1 (102, 103)

    1000 has one batch with a value of 1 (101) and...

  • RE: declaring variable

    Now I see the problem, I missed the fact that you were trying to return the result into the declared variable.

    The only way I can think of doing this is...

  • RE: declaring variable

    Your variable @comp_failed is out of scope when referenced from the dynamic SQL. Dynamic SQL statements run in a separate batch and cannot therefore see local variables.

    Try concatenating the...

  • RE: Locks

    I have experiences something similar before. If you have a queries which is returning a large number of rows from your database and these rows exist in pages which...

  • RE: Where Clause

    Instead of the EXISTS clause, have you considered the IN clause.

    SELECT t1.*

    FROM t1

    WHERE t1.id not in(SELECT t2.id FROM t2)

Viewing 11 posts - 151 through 161 (of 161 total)