--Andrew D. Smith
declare @tbname varchar(200)
select @tbname = 'pd_grc_bgt'
drop table #toWiki
select convert(varchar(255),'||{T^!C4TW80^}Tables in Database||') as txt, -2 as odr into #toWiki
insert into #toWiki VALUES('||{!}Table Name||{!} ||{!} ||{!}Description||',-1)
insert into #toWiki
select '||[' + TABLE_NAME + ']||' + CASE TABLE_TYPE
WHEN 'BASE TABLE' THEN '(*)||[Table'
ELSE '(i)||[View'
END + ']||||', 2 from information_schema.tables t
WHERE T.TABLE_NAME NOT LIKE 'sys%'
AND T.TABLE_NAME <> 'dtproperties'
AND T.TABLE_SCHEMA <> 'INFORMATION_SCHEMA'
insert into #toWiki VALUES('',5)
insert into #toWiki VALUES('SqlToGenerateTableListWiki',6)
select txt from #toWiki order by odr
A database object that can be referenced the same way as a table in SQL statements. Views are defined using a SELECT statement and are analogous to an object that contains the result set of this statement (MS Sql Transact Help)
9/25/2008 3:35:06 PM - FLWCOM-jwdavidson
A SQL Table: A two-dimensional object, consisting of rows and columns, used to store data in a relational database. Each table stores information about one of the types of objects modeled by the database. For example, an education database would have one table for teachers, a second for students, and a third for classes. ( MS Sql Transact Help)
9/24/2008 6:22:07 PM - FLWCOM-jwdavidson
This is SQL that can be used to generate a basic dictionary