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
 Urgent Help: How do I get a table or view list?

Author  Topic 

Overclockedd
Starting Member

6 Posts

Posted - 2007-03-22 : 19:14:16
I accidently deleted the file that I was working on in notepad that had the tables and views that I created. Is there a way to retrieve a list and the code that I put in for the tables and views?

jezemine
Master Smack Fu Yak Hacker

2886 Posts

Posted - 2007-03-22 : 20:20:22
to get a list:

select name from sysobjects where xtype in ('U','V')

or

select * from information_schema.tables
select * from information_schema.views

to generate scripts, check this out: http://www.elsasoft.org/tools.htm


www.elsasoft.org
Go to Top of Page
   

- Advertisement -