4
votes
0answers
56 views

Why is it @@SERVERNAME but not @@DBNAME? [closed]

I'm just curious: To get the server name, I use SELECT @@SERVERNAME but to get the current database name, I use SELECT DB_NAME() Technically, both seem to be scalar functions: @@SERVERNAME is ...
0
votes
0answers
85 views

Name for SELECT equivalent of UPSERT

UPSERT means INSERT and\or UPDATE, is there a standard name for a sproc that will INSERT if necessary and then SELECT? e.g. I want to get the IS of a row that matches fields and give me the ID, if ...
2
votes
2answers
211 views

T-SQL Naming Standard

Is there a recommended (official or not) style from Microsoft regarding naming and casing in T-SQL? If there isn't one from Microsoft then is there one with broad acceptance?
1
vote
2answers
123 views

Naming question for functions: implicit or explicit naming of grouping in function name [closed]

Requesting help with naming TSQL functions. Existing function names (see below for table and relationship descriptions) I currently have functions named as follows: ...