|
 |
asp_databases thread: listing tables in an access database
Message #1 by "Tony Blackman" <tonyblac@n...> on Tue, 16 May 2000 18:00:26 +0100
|
|
I've just subscribed to asp_databases. There sure is a lot of activity.
However I can't spot what I need. Is there an ASP way of listing tables in
an Access database?
Regards
Tony Blackman
Tel (01404) 46600
Fax (01404) 46600
email tonyblac@n...
Message #2 by Kevin D Riggs <kevin.riggs@p...> on Mon, 15 May 2000 20:39:42 -0400
|
|
Tony,
I have tried to access the tables in an Access database to no avail. The
ADODB.Connection object does NOT have an properties or methods that allow
access to tables. However . . .
If you have SQL Server on your NT/2000 server, then you can find an
example of what you want in Chapter 8 of
_Professional_Active_Server_Pages_2.0_ (ISBN 1-861001-26-6). More
specifically, pages 272 - 280 will demonstrate how to "upsize" from an
Access database to an SQL database; create an SQLOLE.SQLServer object and
then use the .Tables properties of the SQLOLE.SQLServer object to access
the names and attributes of tables. It looks like a lot of trouble to go
to since the creator of the database should be able to squirrel away a list
of tables somewhere (even in another database -- try adding a "map" table
to every database you make until MS adds the .Tables property to the
ADODB.Connection object).
Wish I had better news for you. Someone with
_Professional_Active_Server_Pages_3.0_ might have some other input.
KD
Kevin D. Riggs
kevin.riggs@p...
Programmer/Analyst III
UnumProvident Insurance
Chattanooga, TN 37402
(xxx) xxx-xxxx
ICQ - 63816842
AIM - wsi tn
http://www.mindspring.com/~riggsck/
Message #3 by "Ken Schaefer" <ken.s@a...> on Tue, 16 May 2000 11:13:21 +1000
|
|
http://www.learnasp.com/learn/dbtablelists.asp
For Access and SQL Server
Cheers
Ken
----- Original Message -----
From: "Tony Blackman"
To: "ASP Databases" <asp_databases@p...>
Sent: Wednesday, May 17, 2000 3:00 AM
Subject: [asp_databases] listing tables in an access database
>
> I've just subscribed to asp_databases. There sure is a lot of activity.
> However I can't spot what I need. Is there an ASP way of listing tables in
> an Access database?
>
> Regards
>
> Tony Blackman
> Tel (01404) 46600
> Fax (01404) 46600
> email tonyblac@n...
Message #4 by "Ken Schaefer" <ken.s@a...> on Tue, 16 May 2000 18:17:46 +1000
|
|
SQL Server has the sysobject table that you can query, and Access has the
MSysObjects table that you can query. These store metadata about your
database - including your tables.
See:
http://www.learnasp.com/learn/dbtablelists.asp
for examples on how to get this to work.
Cheers
Ken
----- Original Message -----
From: "Kevin D Riggs"
To: "ASP Databases" <asp_databases@p...>
Sent: Tuesday, May 16, 2000 10:39 AM
Subject: [asp_databases] Re: listing tables in an access database
> Tony,
>
> I have tried to access the tables in an Access database to no avail. The
> ADODB.Connection object does NOT have an properties or methods that allow
> access to tables. However . . .
>
> If you have SQL Server on your NT/2000 server, then you can find an
> example of what you want in Chapter 8 of
> _Professional_Active_Server_Pages_2.0_ (ISBN 1-861001-26-6). More
> specifically, pages 272 - 280 will demonstrate how to "upsize" from an
> Access database to an SQL database; create an SQLOLE.SQLServer object and
> then use the .Tables properties of the SQLOLE.SQLServer object to access
> the names and attributes of tables. It looks like a lot of trouble to go
> to since the creator of the database should be able to squirrel away a
list
> of tables somewhere (even in another database -- try adding a "map" table
> to every database you make until MS adds the .Tables property to the
> ADODB.Connection object).
>
>
> Wish I had better news for you. Someone with
> _Professional_Active_Server_Pages_3.0_ might have some other input.
|
|
 |