Re: Map Table to Chunks
Posted in 2004
Chris,
run this sql against sysmaster. Substitute your chunk number for the
chknum value.
select chknum, chksize, (chknum*1048576) chkstart,
((chknum*1048576)+chksize-1) chkend from syschunks
where chknum="1111"
into temp x;select dbinfo('dbspace',a.pe_partnum) dbspace, x.chknum, x.chksize,
b.tabname,
pe_phys, pe_extnum extnum, pe_size ext_size
from sysptnext a, systabnames b, x
where a.pe_partnum = b.partnum
and pe_phys >= x.chkstart
and pe_phys<=x.chkend
order by pe_phys
into temp y;
select dbspace, chknum, chksize, tabname, extnum, ext_size
from y;
-Chris
cbullivant@orange.net.au (Chris Bullivant)
Sent by: owner-informix-list@iiug.org
05/03/2004 02:40 AM
Please respond to
cbullivant@orange.net.au (Chris Bullivant)
To
informix-list@iiug.org
cc
Subject
Map Table to Chunks
Hello All,
I want a script that will allow me to:
a) Enter a chunk number and then display all tables in that chunk
or
b) Enter a table name and then display chunk names/numbers where that
table has an extent.
Oncheck -pe gives too much information as does oncheck -pT, and my
knowledge of awk/perl etc. is pretty rudimentary.
I've been playing with Sysmaster for hours, trying to connect
systabextents (which has a te_physaddr field) to syschkextents (which
has a ce_physaddr field)
but I just can't make it work. So if someone could explain how one of
the systab* tables connects to the syschunk* tables that would be
grand.
I'm using 7.31.UC6 on Solaris 7
Thanks for any help,
Chris Bullivant
sending to informix-list