New features


The think is, the users don’t care about the same things that you care about.

I just added a feature to AFD that lists – for a publication – the places where that publication is used. Its references, what names those references are used in, its child publications.

For me, this is “no worries” material. It’s just a static page. But for the users it’s miraculous. Every time someone sends mail saying “this publication is cited wrongly”, it can’t be fixed until the team confirms that it isn’t used somewhere where the way it is cited is correct for that usage. Previously, this involved database queries done by their tech person and typing in the ids into a browser window. Now it’s just clickety-click. Going to save them hours and hours of time, it seems.

Of more interest to me is my algorithm for managing duplicate publications. The users were very keen that if you mark a record as being a duplicate of some other record, you be able to undo it. For my part, I was keen that I not have to rewrite every query in the system to accommodate this (the publication_id is X, but X had been replaced by Y so we use that).

To manage this, I added a field “original publication_id” to the tables. When a publication is marked as a duplicate, then the publication_id pointers to it are updated. You can make chains and trees of duplicates if you want. To undo, we find all publications that were merged into the one we are unmarking (a small tree walk using a recursive with query), and fix up anything whose “original publication_id” is in that set.

It works a treat. Simple, fast, doesn’t disturb the rest of the system – all that good stuff.

Nearly finished fixing things in AFD, I think. Main important thing remaining is fixing “replaced by” taxa where a record is created from another record which is never made public – it breaks the chain of provenance, because we never expose that middle link.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: