check which version of sql server is installed code example Example: sql server check version SELECT @@version