System Settings MSSQL Tutorial

OBJECT_ID('object')
The syntax of the DB_ID function 
DB_ID('database')