wildcards

  • Comments posted to this topic are about the item wildcards

  • I got an error: "String or binary data would be truncated. The statement has been terminated."

    (0 row(s) affected);-)

    I Have Nine Lives You Have One Only
    THINK!

  • 'Steppenwolf' is 11 characters long so the query will return an error!!!

  • i am also note out the 0

    check it it's not wrong,or you need to change the fifth one

    Every rule in a world of bits and bytes, can be bend or eventually be broken
    MyBlog About Common dialog control
    A Visualizer for viewing SqlCommand object script [/url]

  • thava (9/10/2013)


    i am also note out the 0

    check it it's not wrong,or you need to change the fifth one

    +1.

  • handkot (9/10/2013)


    I got an error: "String or binary data would be truncated. The statement has been terminated."

    (0 row(s) affected);-)

    Just because of "Steppenwolf" having length 11. So insert statement is not executed successfully.

    Correct answer should be "0".

    :crazy:

    I think, nobody check this question before post on SSC. This question is completely wrong.

    Still i didn't believe that this question is posted by "Steve Jones - SSC Editor". :w00t:

    Thanks
    Vinay Kumar
    -----------------------------------------------------------------
    Keep Learning - Keep Growing !!!

  • Danny Ocean (9/10/2013)


    handkot (9/10/2013)


    I got an error: "String or binary data would be truncated. The statement has been terminated."

    (0 row(s) affected);-)

    Just because of "Steppenwolf" having length 11. So insert statement is not executed successfully.

    Correct answer should be "0".

    :crazy:

    I think, nobody check this question before post on SSC. This question is completely wrong.

    Still i didn't believe that this question is posted by "Steve Jones - SSC Editor". :w00t:

    +1

    Totally agree:w00t:

    _______________________________________________________________
    To get quick answer follow this link:
    http://www.sqlservercentral.com/articles/Best+Practices/61537/

  • I think, nobody check this question before post on SSC. This question is completely wrong.

    Still i didn't believe that this question is posted by "Steve Jones - SSC Editor". w00t

    +1.

  • Totally agreed answer should be 0 because of the length of "steppenwolf"

  • CREATE TABLE

    ,INSERT nothing

    ,receive 2?

    ...I will never get any points... ;(

  • The answer is definitely wrong! I ran the exact same query on SQL Server 2008 R2 & I got the same error everyone got:

    Msg 8152, Level 16, State 14, Line 3

    String or binary data would be truncated.

    The statement has been terminated.

    (0 row(s) affected)

    How come parameter mychar VARCHAR(10) and you insert 11 char value?! 'Steppenwolf' Of course the insert statement will fail! :w00t:

    I want my point back 😉

    Thanks & Best Regards,
    Hany Helmy
    SQL Server Database Consultant

  • asanga (9/10/2013)


    CREATE TABLE

    ,INSERT nothing

    ,receive 2?

    ...I will never get any points... ;(

    Don`t worry; this question is exception! 🙂

    Thanks & Best Regards,
    Hany Helmy
    SQL Server Database Consultant

  • Danny Ocean (9/10/2013)


    handkot (9/10/2013)


    I got an error: "String or binary data would be truncated. The statement has been terminated."

    (0 row(s) affected);-)

    Just because of "Steppenwolf" having length 11. So insert statement is not executed successfully.

    Correct answer should be "0".

    :crazy:

    I think, nobody check this question before post on SSC. This question is completely wrong.

    Still i didn't believe that this question is posted by "Steve Jones - SSC Editor". :w00t:

    Couldn`t agree more!

    +1

    Thanks & Best Regards,
    Hany Helmy
    SQL Server Database Consultant

  • I am really amazed of the 16 people (as of now) who got it right! :w00t:

    Hope one of them will post a reply explaining how he got the result without throwing an error.

    Thanks & Best Regards,
    Hany Helmy
    SQL Server Database Consultant

  • The question is broken...

    Msg 8152, Level 16, State 14, Line 5

    String or binary data would be truncated.

    The statement has been terminated.

    (0 row(s) affected)

    Had to try it after seeing so many failed responses.

    Hope this helps...

    Ford Fairlane
    Rock and Roll Detective

Viewing 15 posts - 1 through 15 (of 145 total)

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