Re: dbschema woes
Posted in 1997
MIS Dept wrote:
>
> I have a home-grown database reorg script that uses dbschema -ss to
> generate the necessary information to recreate the tables. So far,
> this hasn't been an issue . . .
>
> . . . but now I'm flirting with the prospect of table
> fragmentation. Unfortunately, dbschema has a bug (#61144) that prevents
> using the -ss option. Short of handling this situation manually or
> creating something on my own, is there something out there that will
> give me my dbschema -ss output along with my frag strategy??
Dear MIS Dept.
I created a while back a series of simple table DLL ESQL/C programs
to overcome the problem you mention, more than anything, and they're available
at http://www.inxutil.com . However they don't generate the DLL for fragments.
( Look for the DDL stuff. ) This is not a perfect solution, but there are some
other DDL programs you could use as well. A 4GL schema report is out there
which I think is also in ESQL/C.
Anyway, I _did_ experiment with pulling the fragments out of the sysmaster
database in a shell-script, then was going to eventually merge that
into the ESQL/C. But never got a round to it. You may want to generate the
fragments separately anyway, so this may not be an issue.
The only nit in using an SQL script to get the expressions out is the
excessive use of paretheses that are stored with an expression, but no big deal.
:-) By this I mean that if you write a really nice expression for a fragement
by expression, and don't use "()", the expression is converted and stored with
the expression anyway. Can be a nuisance, but I understand the "why" behind
this. :-) So you might find yourself just living with it as is, or stripping
out the parens just to make it more readable.
Hope this helps...
Tim