fragment by date expression
Posted in 1997
Hi,
in one of our table 'dta' , the old records are not physically deleted ,
we have a field 'dtadte' that might content the date of the suppression.
This table is now growing very fast, and I want to cut the number of rows
to scan by fragmenting the table in the following way:
ALTER FRAGMENT ON TABLE dta INIT FRAGMENT BY EXPRESSION dtadte is null IN
db1dbs, remainder IN db2dbs;
When I try a select like SELECT * FROM dta WHERE dtadte is null, it
always scans both fragments.
If I fragment using
ALTER FRAGMENT ON TABLE dta INIT FRAGMENT BY EXPRESSION dtadte >'01/01/1900' IN db1dbs, remainder IN db2dbs;
When I try a select like SELECT * FROM dta WHERE dtadte = '01/03/1900',
it scans only one of the fragment, if I use TODAY in the where clause
it scans both fragments again.
It's not very clear to me, any help would be appreciated.
VLG.