Re: List of Tables in a DBspace?
Posted in 1996
Jay,
> I apologize if this is a simple question... but it's been puzzling me
> for quite a bit. I'm interested in obtaining a list of tables
> contained in a particular DBspace. Is this possible either through
> querying the SMI tables or using an Informix provided utility such as
> onstat (with an option that's not apparent to me)? I'm using the
> On-line product version 7.xx. Any help would be greatly appreciated.
> I can be reached at murphy@tc.pw.com.
For a database using its system tables:
select tabname, dbinfo( 'DBSPACE', partnum ) from systables
For all databases using the sysmaster database:
select tabname, dbinfo( 'DBSPACE', partnum ) from sysmaster:systabnames;
This gives you the tablname and the dbspace its in. Works with 7.X
and above.
Regards - Lester
#############################################################################
# Lester Knutsen lester@access.digex.net #
# Advanced DataTools Corporation Voice: 703-256-0267 #
# Grant group privileges for Informix databases with DB Privileges #
# Visit our Web page: http://www.access.digex.net/~lester #
# Washington Area Informix User Group: http://www.access.digex.net/~waiug #
#############################################################################