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
 General SQL Server Forums
 New to SQL Server Programming
 dbo sql server

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2005-08-02 : 10:45:07
Orenh writes "i am new to sql server so sorry for the stupid questions

1. what does dbo stands for?
2. IF EXISTS (SELECT * FROM DBO.SYSOBJECTS WHERE ID =
OBJECT_ID(N'CUSTOMERS')AND OBJECTPROPERTY(ID, N'ICUSTOMERS') = 1
what does the N' ' means?
3.how go i check if database,table,column and stored procedure excist in data base (using stored procedures)?

Thank you very much"

Kristen
Test

22859 Posts

Posted - 2005-08-02 : 11:10:28
Welcome to SQL Team Orenh!

1) dbo is the "Owner" of the table ("DataBase Owner"). Its the default owner, you can have others (e.g. your own login) but in pracice pretty much all the stuff I've ever in SQL Server uses "dbo"

2) N'some text' means that it will be treated as being in Unicode, rather than ASCII - most times it doesn;t matter whether you leave the N out (unless you have chinese characters, or foreign accents etc.)

3) There are some INFORMATION_SCHEMA views that contain data about the database. Everything you want should be in there. Have a look in Books Online ("BoL")

Krsiten
Go to Top of Page

Vijaykumar_Patil
Posting Yak Master

121 Posts

Posted - 2007-01-11 : 09:42:32
I think DBO here stands for Database Object , Sysobjects ( Table) which is a Object of the Database.
Yes DBO stands for DataBase Owner too at login and security properties given to the user for a DB.


Necessity is the mother of all inventions!
Go to Top of Page

MuadDBA

628 Posts

Posted - 2007-01-12 : 10:39:48
Just wanted to chime in here and state that Kristen's answer is correct WRT the DBO abbreviation. By saying dbo.sysobjects, the statement is saying select * from the sysobjects table which is owned by the database owner. You could also have a sysobjects table owned by user crazyjoe, in which case it owuld be crazyjoe.sysobjects

In no way does DBO stand for DatabaseObject. Sorry Vijay :)
Go to Top of Page

Vijaykumar_Patil
Posting Yak Master

121 Posts

Posted - 2007-01-12 : 10:41:18
No Problem crazyjoe , now I know ! Thank you

Necessity is the mother of all inventions!
Go to Top of Page
   

- Advertisement -