Returns the object ID of the specified object.
object_id(object_name)
is the name of a database object, such as a table, view, procedure, trigger, default, or rule. The name can be fully qualified (that is, it can include the database and owner name). Enclose the object_name in quotes.
select object_id("titles")
----------- 208003772
select object_id("master..sysobjects")
----------- 1
object_id, a system function, returns the object’s ID. Object IDs are stored in the id column of sysobjects.
ANSI SQL – Compliance level: Transact-SQL extension.
Any user can execute object_id.
For general information about system functions, see “System functions”.
Functions col_name, db_id, object_name
System procedure sp_help