[OPEN-ILS-DEV] 2.1 RC2 upgrade script testing

Dan Scott dan at coffeecode.net
Sat Aug 20 15:46:01 EDT 2011


On Sat, Aug 20, 2011 at 10:05 AM, Ben Shum <bshum at biblio.org> wrote:
> Hi Mike,
>
> I think this approach will work great, unless the site in question
> doesn't have the correct ID values appropriate to the code.  In our
> case, since we had identified some missing permissions didn't exist yet
> in 2.0, but required it before the community had added them, something
> like "MARK_ITEMS_MISSING_PIECES" was given an ID on our system of 1003
> (a custom ID) and therefore this script couldn't match and find it.
>
> For fun though, I changed the last left join to match on "code" instead
> of "id" and this allowed the script to proceed fully, leaving the custom
> ID's we used intact while inserting the rest of the new permissions.
> Ideally though, I should modify our system to match the
> community-selected IDs as they become known.  I imagine that they're
> given a particular ID for a reason so that they can be assigned to
> specific default permission groups later on?

We're relying on 'code' in 950.sql to create permission groups, at
least in master, so it would make sense IMO to adopt the same approach
in the upgrade script and avoid synthetic ID conflicts for a table
that has a perfectly good natural key.


More information about the Open-ils-dev mailing list