Forum Replies Created

Viewing 15 posts - 2,716 through 2,730 (of 10,144 total)

  • RE: Error in stored procedure

    Koen Verbeeck (1/15/2015)


    ChrisM@Work (1/15/2015)


    or resolve it in the string:

    + '

    FROM employee m

    LEFT JOIN shiftdetails b ON m.empno = b.empno

    where b.shifttype = ''' + @shifttype +

    ...

  • RE: Error in stored procedure

    or resolve it in the string:

    + '

    FROM employee m

    LEFT JOIN shiftdetails b ON m.empno = b.empno

    where b.shifttype = ''' + @shifttype +

    ''' GROUP BY...

  • RE: Today's Random Word!

    BWFC (1/15/2015)


    richxs (1/15/2015)


    Giraffe DBA (1/14/2015)


    SQLRNNR (1/14/2015)


    Ed Wagner (1/14/2015)


    djj (1/14/2015)


    BWFC (1/14/2015)


    Ed Wagner (1/14/2015)


    Stuart Davies (1/14/2015)


    TomThomson (1/13/2015)


    Ed Wagner (1/13/2015)


    SQLRNNR (1/13/2015)


    regex

    Pattern

    Match

    Point

    Edge

    Bono

    Sonny

    Cher

    Babe (i've got you ...)

    Ruth

    Sultan

    Swing

    Swap

  • RE: Are the posted questions getting worse?

    Lynn Pettis (1/14/2015)


    Steve Jones - SSC Editor (1/14/2015)


    Boy, it seems like my questions are getting worse lately. Taking a beating in the QoD.

    Don't worry about it. Some people...

  • RE: Are the posted questions getting worse?

    Koen Verbeeck (1/13/2015)


    FYI, I received the Author of the Year award at MSSQLTips.com!

    Thanks everyone for voting!

    Very well done mate, richly deserved.

  • RE: Restricted LEFT JOIN

    Aaron N. Cutshall (1/14/2015)


    Yet, not surprising when you consider that the parent table has 1.85M rows, the child table has 7.5M rows, and the validation table has 54K. The...

  • RE: Restricted LEFT JOIN

    Aaron N. Cutshall (1/14/2015)


    Chris' solution works well in environments with low to medium data volume, but in the very high data volume environment I have it's too slow. I'm...

  • RE: Counting values

    briankwartler (1/14/2015)


    edwardwill (1/14/2015)


    Actually, it returns:

    Msg 102, Level 15, State 1, Line 4

    Incorrect syntax near ','.

    Perhaps you are missing a comma?

    No, it's version-specific. The code runs on 2008+.

  • RE: Restricted LEFT JOIN

    Aaron N. Cutshall (1/13/2015)


    ChrisM@Work (1/13/2015)


    There are two issues here which might be causing some confusion.

    Firstly, the FROM list of your query, which looks like

    SELECT ...

    FROM parent

    LEFT JOIN child to...

  • RE: Restricted LEFT JOIN

    There are two issues here which might be causing some confusion.

    Firstly, the FROM list of your query, which looks like

    SELECT ...

    FROM parent

    LEFT JOIN child to parent

    INNER JOIN grandchild to...

  • RE: Multiple Condition CASE Statement or Sub-Queries

    SELECT tp.*, s.acct, s.enterDate, s.processDate

    FROM temp tp

    INNER join staticTable s

    ON tp.acct = s.acct

    WHERE

    s.enterDate NOT IN (@conversiondate, @termDate)

    OR -- if s.enterDate IS equal to @conversiondate or @termDate...

  • RE: How to check effect of insert statement during debugging of stored procedure

    SAMDEV (1/12/2015)


    Actually i have hard-coded value for @Rec but it gets calculated for each record being inserted from source table into destination.

    For this purpose I cannot directly insert values from...

  • RE: How to check effect of insert statement during debugging of stored procedure

    SAMDEV (1/12/2015)


    Actually i have hard-coded value for @Rec but it gets calculated for each record being inserted from source table into destination.

    For this purpose I cannot directly insert values from...

  • RE: How to check effect of insert statement during debugging of stored procedure

    SAMDEV (1/12/2015)


    I am debugging a stored procedure. During this I am executing some insert statements on a table which are created from within stored procedure only.

    Now, during my debugging...

  • RE: QUERY HELP minus from max allowed

    You might want to read about table aliases - they will make your code much easier to read:

    SELECT

    12-COUNT(a.PatientID) AS NumberOfPatientsCurrentlyEnrolled,

    a.CourseID,

    l.LocationDesc,

    c.CourseDate

    FROM dbo.tblCourses c

    INNER JOIN dbo.tblLkup_Location l

    ON c.Location_ID...

Viewing 15 posts - 2,716 through 2,730 (of 10,144 total)