Printing table field names and datatypes

J

Jeff

I have MS ACCESS 2000. I have several dozen tables in a database
(each with many fields) and would like to ultimately create a query
and ultimately a user guide report that lists the table name, field
names, and there datatype (if possible). Any suggestions on how to
create the query to do this table of contents?
Thanks
Jeff
 
A

Allen Browne

Simplest approach is:
Tools | Analyze | Documenter.

If you want to do it programmatically, see the example at:
http://members.iinet.net.au/~allenbrowne/func-06.html

You can get the list of tables (but not their field names and types) with
this query:
SELECT MsysObjects.Name FROM MsysObjects
WHERE (([Type] = 1) AND ([Name] Not Like "~*") AND ([Name] Not Like
"MSys*"))
ORDER BY MsysObjects.Name;

Includes type 6 if you want linked tables, and type 4 for ODBC linked
tables.
 
J

Jeff

Thanks! Is exactly what I was looking for. Jeff


Allen Browne said:
Simplest approach is:
Tools | Analyze | Documenter.

If you want to do it programmatically, see the example at:
http://members.iinet.net.au/~allenbrowne/func-06.html

You can get the list of tables (but not their field names and types) with
this query:
SELECT MsysObjects.Name FROM MsysObjects
WHERE (([Type] = 1) AND ([Name] Not Like "~*") AND ([Name] Not Like
"MSys*"))
ORDER BY MsysObjects.Name;

Includes type 6 if you want linked tables, and type 4 for ODBC linked
tables.

--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

Jeff said:
I have MS ACCESS 2000. I have several dozen tables in a database
(each with many fields) and would like to ultimately create a query
and ultimately a user guide report that lists the table name, field
names, and there datatype (if possible). Any suggestions on how to
create the query to do this table of contents?
Thanks
Jeff
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top