SQL Server stored procedure naming

We have started naming our stored procedures as [16_TestStoredProc]. Are there any implications naming a stored procedure like this?

I am not going to explain why we are doing this. It is not that I have issues with this, but would to any implications.

Answers 1

  • There are no technical issues with this.

    It isn't going to make any difference to SQL Server.

    From a usability point of view identifier names that begin with a number must always be quoted so

    exec some_schema.16_TestStoredProc
    

    would not be valid and you must always use

    exec some_schema.[16_TestStoredProc]
    

    Also when viewing the stored procedures alphabetically sorted - e.g. in Object explorer this prefix may well not be helpful in trying to find a stored procedure and as they are ordered lexicographically it may be somewhat inconvenient that 18_TestStoredProc precedes 2_TestStoredProc.

    I am not going to explain why we are doing this

    Well perhaps you have good reasons. As you aren't going to share them it isn't possible for us to comment on them.


Related Questions