I'm working on a report, and I'd like to see data related to the 942$c field. We want to look at instances where it's different than 952$y, and validate these. Where (if anywhere) is this field stored in the database? I can't find it. It doesn't seem to always match either item.itype or biblioitem.itemtype. Joel Coehoorn Director of Information Technology 402.363.5603 *jcoehoorn@york.edu <jcoehoorn@york.edu>* *Please contact helpdesk@york.edu <helpdesk@york.edu> for technical assistance.* The mission of York College is to transform lives through Christ-centered education and to equip students for lifelong service to God, family, and society
Hi Joel, The full MARCXML record is available in the metadata field of the biblio_metadata table. You need to use that table in your query and an ExtractValue function to get the particular subfields you’re interested in. I would recommend looking at the Reports library in the wiki which should be linked in the sidebar of Reports. Best, Eric On Tue, Dec 10, 2019 at 07:30 Coehoorn, Joel <jcoehoorn@york.edu> wrote:
I'm working on a report, and I'd like to see data related to the 942$c field. We want to look at instances where it's different than 952$y, and validate these. Where (if anywhere) is this field stored in the database? I can't find it. It doesn't seem to always match either item.itype or biblioitem.itemtype.
Joel Coehoorn Director of Information Technology 402.363.5603 *jcoehoorn@york.edu <jcoehoorn@york.edu>*
*Please contact helpdesk@york.edu <helpdesk@york.edu> for technical assistance.*
The mission of York College is to transform lives through Christ-centered education and to equip students for lifelong service to God, family, and society _______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz https://lists.katipo.co.nz/mailman/listinfo/koha
-- Best, ERIC PHETTEPLACE Systems Librarian (he/him) ephetteplace@cca.edu | o 510.594.3660 5212 Broadway | Oakland, CA | 94618 :(){ :|: & };:
Hi Eric and everyone I'm having the same requirement as Joel Taken from koha wiki report SELECT ExtractValue(( SELECT metadata FROM biblio_metadata WHERE biblionumber=12), '//datafield[@tag="942"]/subfield[@code>="c"]') AS ITEM This sql is working fine for tag 942$c but not for tag 952$y Is there any special extractvalue for 952? Thanks in advance Kind regards fauzi AB -- Sent from: http://koha.1045719.n5.nabble.com/Koha-general-f3047918.html
Hi, the 952 tag is used for item information on export and import, but within Koha the item information is only kept in the items table and not as part of the MARC data. If you want to query for the itemtype (952$y) you need to use the items table, for example: SELECT items.itype FROM items; Hope this helps, Katrin On 18.01.20 16:23, fauzi AB wrote:
Hi Eric and everyone
I'm having the same requirement as Joel
Taken from koha wiki report
SELECT ExtractValue(( SELECT metadata FROM biblio_metadata WHERE biblionumber=12), '//datafield[@tag="942"]/subfield[@code>="c"]') AS ITEM
This sql is working fine for tag 942$c but not for tag 952$y
Is there any special extractvalue for 952?
Thanks in advance Kind regards fauzi AB
-- Sent from: http://koha.1045719.n5.nabble.com/Koha-general-f3047918.html _______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz https://lists.katipo.co.nz/mailman/listinfo/koha
Dear Katrin Noted with thanks Btw xml data file; i could see this kind of data & would like to extract those tags ... <datafield tag="952" ind1=" " ind2=" "> <subfield code="0">0</subfield> <subfield code="1">0</subfield> <subfield code="2">lcc</subfield> <subfield code="4">0</subfield> <subfield code="7">0</subfield> <subfield code="9">117534</subfield> <subfield cod ... fauzi -- Sent from: http://koha.1045719.n5.nabble.com/Koha-general-f3047918.html
Hi, where are you seeing this in the XML? In the database or somewhere else in Koha? Which version of Koha are you using? Katrin On 19.01.20 18:45, fauzi AB wrote:
Dear Katrin
Noted with thanks
Btw xml data file; i could see this kind of data & would like to extract those tags ...
<datafield tag="952" ind1=" " ind2=" "> <subfield code="0">0</subfield> <subfield code="1">0</subfield> <subfield code="2">lcc</subfield> <subfield code="4">0</subfield> <subfield code="7">0</subfield> <subfield code="9">117534</subfield> <subfield cod ...
fauzi
-- Sent from: http://koha.1045719.n5.nabble.com/Koha-general-f3047918.html _______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz https://lists.katipo.co.nz/mailman/listinfo/koha
Hi all, Just a guess—is this coming from a MARCXML export from the catalog? The answer to your question has already been offered, however. The 952 fields are for related items. You should use the items table in your report if you want to retrieve that data. If you stated exactly what fields you were interested in it'd be easy to construct an example report. On Sun, Jan 19, 2020, 12:52 PM Katrin Fischer <katrin.fischer.83@web.de> wrote:
Hi,
where are you seeing this in the XML? In the database or somewhere else in Koha? Which version of Koha are you using?
Katrin
On 19.01.20 18:45, fauzi AB wrote:
Dear Katrin
Noted with thanks
Btw xml data file; i could see this kind of data & would like to extract those tags ...
<datafield tag="952" ind1=" " ind2=" "> <subfield code="0">0</subfield> <subfield code="1">0</subfield> <subfield code="2">lcc</subfield> <subfield code="4">0</subfield> <subfield code="7">0</subfield> <subfield code="9">117534</subfield> <subfield cod ...
fauzi
-- Sent from: http://koha.1045719.n5.nabble.com/Koha-general-f3047918.html _______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz https://lists.katipo.co.nz/mailman/listinfo/koha
Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz https://lists.katipo.co.nz/mailman/listinfo/koha
Hi Eric 'coming from a MARCXML export from the catalog?' yes 'The answer to your question has already been offered...' Just wondering; the data in table biblio_metadata.metadata is the same in biblio & items table? Thanks fauzi -- Sent from: http://koha.1045719.n5.nabble.com/Koha-general-f3047918.html
Hi Katrin 'where are you seeing this in the XML?' Eris is right; coming from a MARCXML export from the catalog I assume from biblio_metadata.metadata table 'version of Koha?' 18.11.06 Thanks fauzi -- Sent from: http://koha.1045719.n5.nabble.com/Koha-general-f3047918.html
Hi Fauzi, the 952 is not in the MARCXML in your database, it's added when you export from the items table. So what you see in the export doesn't exactly match what's in the database. You really need to query the items table, and it's way easier to query than the XML too. Katrin On 20.01.20 03:58, fauzi AB wrote:
Hi Katrin
'where are you seeing this in the XML?' Eris is right; coming from a MARCXML export from the catalog I assume from biblio_metadata.metadata table
'version of Koha?' 18.11.06
Thanks fauzi
-- Sent from: http://koha.1045719.n5.nabble.com/Koha-general-f3047918.html _______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz https://lists.katipo.co.nz/mailman/listinfo/koha
Hi Katrin Noted with thanks fauzi -- Sent from: http://koha.1045719.n5.nabble.com/Koha-general-f3047918.html
participants (4)
-
Coehoorn, Joel -
Eric Phetteplace -
fauzi AB -
Katrin Fischer