Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

sql server check table exists

IF EXISTS 
  (SELECT object_id FROM sys.tables
  WHERE name = 'Artists'
  AND SCHEMA_NAME(schema_id) = 'dbo')
  PRINT 'The table exists'
ELSE 
  PRINT 'The table does not exist';
Source by database.guide #
 
PREVIOUS NEXT
Tagged: #sql #server #check #table #exists
ADD COMMENT
Topic
Name
4+6 =