[OPEN-ILS-DEV] SUGGESTION: Tagging DB schema versions

Brandon W. Uhlman brandon.uhlman at bclibrary.ca
Thu Aug 21 20:05:02 EDT 2008


Hi!

As part of trying to track down a problem, I'm wondering if my  
installed software version and the database schema that I'm working on  
have diverged.

To that end, I'm going through collections of schema upgrade scripts  
to see if new schemata from each of the scripts have been added to my  
instance. It would be a lot easier if we took a page from (say) Ruby  
on Rails, which includes in their 'database migrations' a version tag,  
which lets me know which revision of the database my schema is  
currently at.

This could take the form of a single table, for example,  
config.db_schema_version, with a single column, version, and a single  
record, with a string representing the current version. In the short  
term we could keep the string for human use, but over the longer term,  
we could automate schema upgrades by watching this value.

Lately, I feel like I've been throwing out lots of ideas that require  
coding, and not submitting lots of code. I hope that will change soon.  
:-p

Any comments on this idea?

Brandon



======================================
Brandon W. Uhlman, Systems Consultant
Public Library Services Branch
British Columbia Ministry of Education
Vancouver, BC (and Lillooet, BC)

Phone: (604) 660-2972 or (250) 256-0344
E-mail: brandon.uhlman at gov.bc.ca
         brandon.uhlman at bclibrary.ca



More information about the Open-ils-dev mailing list