RE: SqlConnection question

Tech-Archive recommends: Fix windows errors by optimizing your registry

From: Senguttuvan (cheran_76_at_yahoo.com)
Date: 04/20/04


Date: Tue, 20 Apr 2004 16:46:03 -0700

Hi Sam,
        
      The following query will return 1 if the table exist in the database. Just replace the 'Table Name' with the table name you want to check for the existence.

      select count(*) from SYSOBJECTS where name = 'Table Name'

Thanks,
Senguttuvan

     
     ----- Sam Johnson wrote: -----
     
     Hi,
     
     how can I test if a specific table on an SQL- Server (that I'm connected to) exists or not?
     
     Thanks
     Sam