re: How to determine the DBSpace a table...
Posted in 1993
Glen,
if you are looking at a specific table(as apposed to all tables in a dbspace),
then do the following:
isql databasename
select tabname,
hex(partnum)
from systables
where tabname = 'your_table'
this should yield the following output (your only interested in the 3rd and 4th
characters of the hex(partnum) stuff):
tabname (expression)
your_table 0x010001D1
^^
from this information, you can tell that the table resides in the '01'
dbspaces. you can then dereference this by running tbstat -d and looking for
1 in the number column for dbspaces. in this example, the table is in the
rootdbs.
(hermes1)/home_hermes1/baskett>tbstat -d
RSAM Version 5.00.UC3 -- On-Line -- Up 12 days 23:47:52 -- 31832 Kbytes
Dbspaces
address number flags fchunk nchunks flags owner name
1001f068 1 1 1 1 N informix rootdbs
1001f098 2 1 2 2 N informix bsi_dbspace_001
1001f0c8 3 1 3 2 N informix bsi_dbspace_002
1001f0f8 4 1 4 1 N informix bsi_dbspace_003
1001f128 5 1 5 1 N informix bsi_dbspace_004
1001f158 6 1 6 2 N informix bsi_dbspace_005
1001f188 7 1 7 2 N informix bsi_dbspace_006
7 active, 30 total
Chunks
address chk/dbs offset size free bpages flags pathname
1001b508 1 1 25 1038500 601861 PO- /dev/dbdisk1
1001b5a0 2 2 25 1038500 124805 PO- /dev/dbdisk2
1001b638 3
* * *
--
regards,
+----------------------------------------------------------------------------+
| . . | |
| ... ... | Bob Baskett |
| ..... ..... | Software Engineer, DBA |
| .. ... .. | Business Systems Integration Group |
| . . . | Semiconductor Products Sector |
| | Mesa, AZ |
| Motorola, Inc. | |
|----------------------------------------------------------------------------|
| 'connectionLESS IS MORE' -- Data Broker |
|----------------------------------------------------------------------------|
| Duct tape is like the force. It has a light side, and a dark side, and |
| it holds the universe together ... |
| -- Carl Zwanzig |
+----------------------------------------------------------------------------+