I am using sql-server 2012
and I have this query
create table t
(
id int not null,
name varchar(10)
);
select OBJECT_NAME(object_id) as table_name,type,name as table_name,type_dec
from sys.indexes
where object_id=OBJECT_ID(N'dbo.t',N'U')
whats the difference in object_id and OBJECT_ID
and what is the use of writing N''
The query returns same result: with or without N