Usage of Null

  • Comments posted to this topic are about the item Usage of Null

    Regards,
    Bhav
    SSISDevelopers.wordpress.com[/url]

  • An easy one for the day.

    SET ANSI_NULLS ON --> enforces SQL-92 standard which says that all equal to and not equal to with NULL evaluates to FALSE.

    ~ Lokesh Vij


    Guidelines for quicker answers on T-SQL question[/url]
    Guidelines for answers on Performance questions

    Link to my Blog Post --> www.SQLPathy.com[/url]

    Follow me @Twitter

  • Really easy one. Just look the first if condition, it gives result as 'Statement1 : Not null'. Now only Option 2nd having this one. I don't need to read complete question.:-D

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

  • Danny Ocean (6/4/2013)


    Really easy one. Just look the first if condition, it gives result as 'Statement1 : Not null'. Now only Option 2nd having this one. I don't need to read complete question.:-D

    +1

    I also observed the same 🙂

    ~ Lokesh Vij


    Guidelines for quicker answers on T-SQL question[/url]
    Guidelines for answers on Performance questions

    Link to my Blog Post --> www.SQLPathy.com[/url]

    Follow me @Twitter

  • Starting from SQL2000 SET ANSI_NULLS OFF is a real deprecated option.

    From BOL:

    In a future version of SQL Server, ANSI_NULLS will always be ON and any applications that explicitly set the option to OFF will generate an error. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.

  • Carlo Romagnano (6/5/2013)


    Starting from SQL2000 SET ANSI_NULLS OFF is a real deprecated option.

    From BOL:

    In a future version of SQL Server, ANSI_NULLS will always be ON and any applications that explicitly set the option to OFF will generate an error. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.

    +1. nice and easy question....

    Manik
    You cannot get to the top by sitting on your bottom.

  • It was too easy. The first statement let choose the correct answer.

  • This was removed by the editor as SPAM

  • Easy one for the day 🙂

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

  • Danny Ocean (6/4/2013)


    Really easy one. Just look the first if condition, it gives result as 'Statement1 : Not null'. Now only Option 2nd having this one. I don't need to read complete question.:-D

    Right, only one option available so didn't required to read the all options 🙂

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

  • Lokesh Vij (6/4/2013)


    An easy one for the day.

    SET ANSI_NULLS ON --> enforces SQL-92 standard which says that all equal to and not equal to with NULL evaluates to FALSE.

    I think technically it evaluates to "UNKNOWN"

    http://msdn.microsoft.com/en-us/library/ms191270(v=sql.105).aspx.

  • Danny Ocean (6/4/2013)


    Really easy one. Just look the first if condition, it gives result as 'Statement1 : Not null'. Now only Option 2nd having this one. I don't need to read complete question.:-D

    +1

    Very easy one today 😀

    Need an answer? No, you need a question
    My blog at https://sqlkover.com.
    MCSE Business Intelligence - Microsoft Data Platform MVP

  • All,

    Yes easy, but helpful. We are in the process of converting a whole mess of 10-15 year old Access/SQL Server applications and we are finding some "@Var = NULL" buried in some of the old stored procedures causing some interesting side effects.

    It is interesting to see how coding practices and technology change over the years. This application also has a ton of triggers implementing RI, user defined error messages (which were never brought forward when we moved the databases to a new server), identity columns defined by a separate table that is incremented when a new row is inserted as well as some interesting database designs.

    Anton

  • Danny Ocean (6/4/2013)


    Really easy one. Just look the first if condition, it gives result as 'Statement1 : Not null'. Now only Option 2nd having this one. I don't need to read complete question.:-D

    Yup - very easy

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

  • Koen Verbeeck (6/5/2013)


    Danny Ocean (6/4/2013)


    Really easy one. Just look the first if condition, it gives result as 'Statement1 : Not null'. Now only Option 2nd having this one. I don't need to read complete question.:-D

    +1

    Very easy one today 😀

    +1 😀

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

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