|Age||Commit message (Collapse)||Author||Files||Lines|
Broken when adding the staff_alias.c_search GENERATED COLUMN. The column
was being created in the temporary table, including the NOT NULL
constraint but excluding the GENERATED part, so it would get filled with
NULL and throw an error.
I had wanted to split this up into multiple commits and roll out in
stages, but couldn't really find a natural way to do so. There are
several places that take a generic identifier and expect it to work the
same for all entries they support, so changing one entry at a time
wasn't going to be any easier. Only the tags & traits haven't been
updated yet, I'll convert those later.
While this is a major change and affects a lot of code, the individual
changes are all pretty simple. I'm surprised how much code did not have
to be updated at all. No doubt I've missed a few places, though, so this
commit will almost certainly break something.
Been wanting to do this for a while...
I've kept util/sql as a symlink for compatibility with the devdump, old
update scripts and other code I may have forgotten. I'll remove it
I always avoided using the VNDB::* schema for non-web related utility
modules, but thats pretty silly (especially as I'm slowly trying to move
away from the old VNDB::* web code).
This changes quite a bit to the way the editing functions work. Because
these functions are very repetitive and it's easy to keep things out of
sync, I created a script to generate them automatically. I had to rename
a few function and table names for consistency to make this work.
Since database entries don't have a 'latest' column anymore, and since
the order in which tables are updated doesn't have to be fixed, I
dropped many of the SQL triggers and replaced them with a
edit_committed() function which is called from edit_*_commit() and
checks for stuff to be done.
Don't forget to run 'make' before importing the update script.