Insert with OUTPUT clause

  • vk-kirov


    Points: 7686

    Comments posted to this topic are about the item Insert with OUTPUT clause

  • Koen Verbeeck

    SSC Guru

    Points: 258965

    Nice question. Of course I got it wrong, as I thought it would be the same answer as the QotD from 13th of May. 🙂

    Need an answer? No, you need a question
    My blog at
    MCSE Business Intelligence - Microsoft Data Platform MVP

  • Arjun SreeVastsva


    Points: 7135

    Good Question .....By Seriously I attempted the question luckly my answer is match with answer....

  • ziangij


    Points: 7240

    thanks... i had to read BOL to get this right... 🙂

  • Richard M.


    Points: 7288

    Nice question... with a twist from the QOD from the other day 😀

    For better assistance in answering your questions, click here[/url]

  • rjv_rnjn

    Hall of Fame

    Points: 3023

    A twist on previous question agreed, but I do not agree with the choice of answers. It is a bit too vague to select that as an answer.

  • sjimmo


    Points: 11139

    Agree with rjv:

    A twist on previous question agreed, but I do not agree with the choice of answers. It is a bit too vague to select that as an answer.

    Tricky with the select at the end. Good question, makes one think. I do a lot with triggers and output statements and had doubts.

    Steve Jimmo
    Sr DBA
    “If we ever forget that we are One Nation Under God, then we will be a Nation gone under." - Ronald Reagan

  • UMG Developer


    Points: 13482

    Good question, it made me think some. I did refer back to the previous similar question to see what was different, which helped.

  • Dave Jones - CRC


    Points: 429

    Nice question. I almost got it wrong because when I read it, I assumed the output had a "into @myTable" after it. But when I read it again (and actually paid attention this time), I saw it didn't. 😀

  • deepak.a


    Points: 5330

    Thanks For the Good Question 🙂


    SSC Guru

    Points: 281252

    Thanks - nice question.

    Jason...AKA CirqueDeSQLeil
    I have given a name to my pain...MCM SQL Server, MVP
    Posting Performance Based Questions - Gail Shaw[/url]
    Learn Extended Events

  • TomThomson

    SSC Guru

    Points: 104773

    Another good question, but a bit close to the one posted 6 days earlier - I was catching up on QOTD today after a while of not having time so I got to these two questions maybe 15 minutes apart (would have been less if I hadn't spent time thinking about the first one). If I hadn't seen the previous one, and read the references in the explanation and played a bit with output clauses to get a better feel I would probably have guessed this one wrong (picked the syntax error instead of another error).


  • ipkunte

    SSC Enthusiast

    Points: 123

    I received the following error message when I ran the script on SQL Server 2005.

    Msg 170, Level 15, State 1, Line 2

    Line 2: Incorrect syntax near 'OUTPUT'.

    Can someone put a light on this?

Viewing 13 posts - 1 through 13 (of 13 total)

You must be logged in to reply to this topic. Login to reply