why does the primary filegroup needs brackets in alter statement?

  • In the below statement , why does primary needs to be enclosed in square brackets.?

    ALTER DATABASE Employee

    MODIFY FILEGROUP [PRIMARY] --- why are the square brackets needed here?

    DEFAULT

  • invaliddba (5/14/2011)


    In the below statement , why does primary needs to be enclosed in square brackets.?

    ALTER DATABASE Employee

    MODIFY FILEGROUP [PRIMARY] --- why are the square brackets needed here?

    DEFAULT

    Because PRIMARY is a Keyword you must enclose it in square brackets.

    For better, quicker answers on T-SQL questions, click on the following...
    http://www.sqlservercentral.com/articles/Best+Practices/61537/

    For better answers on performance questions, click on the following...
    http://www.sqlservercentral.com/articles/SQLServerCentral/66909/

  • Square bracket define when name of the object is like

    1-jahanzaib is not need to define brackets

    2-[jahan-zaib] is need to define in backet

    Regards,
    Syed Jahanzaib Bin Hassan
    BSCS | MCTS | MCITP | OCA | OCP | OCE | SCJP | IBMCDBA

    My Blog
    www.aureus-salah.com

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

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