[Koha] How to extract data from marcxml.biblioitmes ?
Chris Nighswonger
cnighswonger at foundations.edu
Wed May 12 04:39:46 NZST 2010
On Tue, May 11, 2010 at 12:27 PM, Colin Campbell
<colin.campbell at ptfs-europe.com> wrote:
>
> My XPATH (such as it ever was) is rather rusty but playing with the
> ExtractValue function it seems happy if I select on datafield's
> attributes or subfield's attributes but not both. So I can extract tag x
> or subfield y but not subfield y of tag x. Anyone have a better xpath
> expression.
FWIW, here is an example I worked up some time ago:
'SELECT ExtractValue((SELECT marcxml FROM biblioitems WHERE
biblionumber=14), '//datafield[@tag="260"]/subfield[@code>="b"]') AS
ITEM;'
Which returns all subfields b from tag 260 for a given bib.
ExtractValue is not extremely flexible it seems, but potentially useful.
Kind Regards,
Chris
More information about the Koha
mailing list