Forum Replies Created

Viewing 15 posts - 8,986 through 9,000 (of 10,144 total)

  • RE: problem in query

    pat (1/6/2009)


    still the same it is not inserting all records. the file has 695 records and i only get 29 with initial setup or 204 after having is null criteria!!

    You've...

  • RE: UPDATE from CTE

    Philip Horan (1/6/2009)


    Thanks guys and yes I am an old git 🙂

    Old Dogs, new tricks....possible?

    Thanks,

    Phil.

    'Course! I'm an old git and I learn something new here every day - see above,...

  • RE: problem in query

    Cool.

    Now, change thisIF @test1 + @test2 + @test3 > 0

    to this IF ISNULL(@test1, 0) + ISNULL(@test2, 0)+ ISNULL(@test3, 0)> 0

    Also, put a new line in as follows...

    ...

  • RE: problem in query

    Pat, are you able to answer the questions?

    Chris Morris (1/6/2009)


    pat (1/6/2009)


    thanks for reformating.

    It needs to go on to end of last insert!!

    Thanks

    What does?

    How many times does the PRINT statement execute?

    What...

  • RE: problem in query

    pat (1/6/2009)


    thanks for reformating.

    It needs to go on to end of last insert!!

    Thanks

    What does?

    How many times does the PRINT statement execute?

    What values do you get for @test1, @test2 & @test3?...

  • RE: problem in query

    How many times does the PRINT statement execute?

    Here's the whole thing reformatted a little for readability:

    [font="Courier New"]ALTER PROCEDURE [dbo].[testproc]

        @srcFilename VARCHAR(256)

    AS

    BEGIN

    -- SET NOCOUNT ON added to prevent extra result sets from

    --...

  • RE: Are the posted questions getting worse?

    GilaMonster (1/6/2009)


    Chris Morris (1/6/2009)


    GilaMonster (1/6/2009)


    I recommend a 20-sided dice.

    Six is sufficient...http://en.wikipedia.org/wiki/The_Dice_Man

    Maybe for you. 😉 I play D&D. The 20-sided dice is the most important one.

    I have 4, 6, 8, 10...

  • RE: Are the posted questions getting worse?

    GilaMonster (1/6/2009)


    Grant Fritchey (1/6/2009)


    URGENT!

    How do you pick indexes... Oh lordy

    I recommend a 20-sided dice.

    Six is sufficient...http://en.wikipedia.org/wiki/The_Dice_Man

  • RE: Take off matching invoice from list

    SELECT s.name, s.PHC_ID, s.[Contact Date], s.[Referral Date], s.activity__2

    FROM dbo_pod_surgery s

    WHERE s.PHC_ID IN ('22/15729', '23/13278')

    AND s.activity__2 <> 'AS0630'

  • RE: need a simple query

    shiwani2002sg (1/5/2009)


    and its stated that the value of A would be same in both the tables , row-by-row.

    This looks like homework, but at least you're putting in some...

  • RE: UPDATE from CTE

    RBarryYoung (1/5/2009)


    See that Update solution that I just posted in the "Cursors Be Gone" thread. It's got a derived table, that arguably could/should be a CTE: http://www.sqlservercentral.com/Forums/FindPost630181.aspx

    Thanks Barry, I...

  • RE: UPDATE from CTE

    Philip Horan (1/5/2009)


    Chris I was just playing with the CTE concept as I am quite new to TSQL.

    Moving forward part of the learning process is to know when to employ...

  • RE: SELECTing from Excel using OPENROWSET

    Check that the file is not already open.

  • RE: Stripping alpha numeric charecters

    GSquared (1/5/2009)


    A single-pass, hard-coded replace command, on the other hand, only took 194 milliseconds to do the same thing:

    update #T

    set Col4 =

    replace(

    replace(

    replace(

    replace(

    replace(

    replace(

    replace(

    replace(

    replace(

    replace(col1, '1', ''),

    '2', ''),

    '3', ''),

    '4', ''),

    '5', ''),

    '6',...

  • RE: What Server Am I Running From

    Hi Mattie

    This is how I've implemented your scenario:

    I have a reporting db on each server instance, call it say ReportingDB. The reporting db contains sp's, functions and tables which relate...

Viewing 15 posts - 8,986 through 9,000 (of 10,144 total)