Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 Meaning of N' in "object_id(N'[dbo].[xxxxx]

Author  Topic 

atulkukreja
Starting Member

13 Posts

Posted - 2009-09-05 : 12:55:38
What is the meaning / purpose of N' in "if exists (select * from dbo.sysobjects where id = object_id(N'[dbo][tablename].......

Thanks.

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2009-09-05 : 12:57:06
It declares to treat the following string as NVARCHAR instead of VARCHAR.


No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page

atulkukreja
Starting Member

13 Posts

Posted - 2009-09-05 : 20:09:34
Thanks for responding.
So it is really not needed for checking for the existence of a table, right?

scptech
Go to Top of Page

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2009-09-06 : 08:37:13
That depends on used charset and I would say don't bother about that.


No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page
   

- Advertisement -