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 2000 Forums
 Transact-SQL (2000)
 How to stop Error

Author  Topic 

real_pearl
Posting Yak Master

106 Posts

Posted - 2004-12-17 : 02:07:01
If an object does not exist, SQL Server generates error

208- Invalid object name

I want to handle the error but dont want the user to see it. How can I do this?

spirit1
Cybernetic Yak Master

11752 Posts

Posted - 2004-12-17 : 05:40:32
you can check if the object exists:
if object_id('someName') is null
select 1
else
select 2

Go with the flow & have fun! Else fight the flow
Go to Top of Page
   

- Advertisement -