[wp-hackers] Table updater wish

Owen Winkler ringmaster at midnightcircus.com
Mon Aug 2 12:11:43 UTC 2004


> No, and the new installer in the CVS doesn't have any unecessary steps.

On the step two page of the installer in CVS, there is nothing for the user
to do but go to the third step.  The third step installs only the user table
and default user.  I have maintained this behavior in the update I'm
writing, but it doesn't seem entirely necessary.  Any special plans for this
step?

A separate question regarding table indices:

The upgrade functions (which are also run during the installer) drop and
re-add a bunch of indices on tables.  My goal was to extract the required
index data from the build queries, verify it against the current table
indices, and make changes as required to bring each table up to snuff.  I
thought that this would help eliminate a lot of the upgrade code.

But the upgrade code is doing a lot of weird stuff with indices.  I've never
seen a database prior to 1.2 so I don't know how these things are build, but
it seems that there could be a slew of numbered indices all on the same
column that would need to be dropped.

Should I bother with the index updates, then, since there is no reason for
my function to assume it should delete any numbered indices?

I've written a bunch of code that will add missing indices, but the code
will not drop an existing index on a table, even if its name matches the
index.  Is this even required?

Otherwise, the function is done and works, and all that remains is removing
the code from the upgrade_xxx functions that executes ALTER TABLE
statements.  I also might like to test it on older databases.  Any idea
where I can get one of those?

Owen






More information about the hackers mailing list