Help on auto generated scripts

  • hi all, when you use the auto generate script options there are few things

    which i m confused of

    1. what is the significance of

    SET ANSI_NULLS ON

    GO

    SET QUOTED_IDENTIFIER ON

    GO

    SET ANSI_PADDING ON, what this do?

    2.IN the Table creation script at last it is : ON [Primary]

    do these things affect performance?

    Any of your answer is appreciated..

  • You can lookup each of the set statements in Books on Line to get full definitions

    SET ANSI_NULLS ON

    Sets the connection to use ANSI standard NULL handling. This basically means that you cannot use

    Where x = NULL you need to use Where X Is Null

    SET QUOTED_IDENTIFIER ON

    Means that you use single quotes to delimit strings and double quotes are used for object names.

    SET ANSI_PADDING ON, what this do?

    Means that varchar columns keep trailing blanks when stored in the database

    ON [Primary]

    This is the filegroup that the object will be created on. Lookup up CREATE TABLE in BOL for more details.

    All of the SET options are the recommend way to run SQL Server. The performance affect of CREATE object ON filegroup depends on the configuration of your server. You can potentially get better performance by having multiple filegroups especially if the filegroups are on different physical drives.

    Jack Corbett
    Consultant - Straight Path Solutions
    Check out these links on how to get faster and more accurate answers:
    Forum Etiquette: How to post data/code on a forum to get the best help
    Need an Answer? Actually, No ... You Need a Question

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

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