Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 

Get your favorite SSC scripts directly in SSMS with the free SQL Scripts addin. Search for scripts directly from SSMS, and instantly access any saved scripts in your SSC briefcase from the favorites tab.
Download now (direct download link)

Getting schemas for your tables

By Gaby Abed,

Try this script on Adventureworks where there is more than one schema. A quick way to access the tables you want is to pop the second script into a temp table by selecting only the tables you need (or don't), and create your own sp_msforeachtable procedure.

Cheers!

 

-- Update Oct. 7, 2008: Cleaned up and updated some of the code

Total article views: 636 | Views in the last 30 days: 2
 
Tags
quotename    
schemas    
sql server 2005    
 
Contribute