Lookup tool that harvests barcodes within call number range? #35
LincolnUniLTL
started this conversation in
General
Replies: 2 comments
-
Beta Was this translation helpful? Give feedback.
0 replies
-
|
Hi Tom,
Thanks for your reply. I thought that there would be a way to achieve what we require along the lines you described but, as we are having to put most of our collection in storage due to earthquake strengthening of our entire building, the limit of 25 records makes this impractical.
I am now pursuing another avenue.
But thank you for your time, advice, and your app.
Regards,
Craig.
From: tventimi ***@***.***>
Sent: Friday, 3 October 2025 4:19 am
To: pulibrary/ExcelAlmaLookup ***@***.***>
Cc: Digital Access ***@***.***>; Author ***@***.***>
Subject: Re: [pulibrary/ExcelAlmaLookup] Lookup tool that harvests barcodes within call number range? (Discussion #35)
Caution: This email originated from outside our organisation. Do not click links or open attachments unless you recognize the sender and know the content is safe.
Hello Craig,
Thanks for reaching out, and it is good to know about your use case. The Alma SRU integration does support the kind of search you want to do, though I'm afraid the Excel plugin only supports it somewhat awkwardly at present. I will explain first how it works in SRU, as you might find it easiest to do the query directly if you don't mind working with the raw data. The following URL queries the Princeton catalog for all LC call numbers between CD500 and CD599
https://princeton.alma.exlibrisgroup.com/view/sru/01PRI_INST?version=1.2&operation=searchRetrieve&query=alma.PermanentCallNumber+>=+CD500+AND+alma.PermanentCallNumber+<=+CD599+AND+alma.permanentCallNumberType+=+0<https://princeton.alma.exlibrisgroup.com/view/sru/01PRI_INST?version=1.2&operation=searchRetrieve&query=alma.PermanentCallNumber+%3e=+CD500+AND+alma.PermanentCallNumber+%3c=+CD599+AND+alma.permanentCallNumberType+=+0>
This gives you the raw MARC-XML, with the call numbers in field AVA$d. If you want the barcodes, add the URL parameter &recordSchema=isohold. As you can see in the URL, this is a boolean search that specifies the range using the >= and <= operators. The alma.premanentCallNumberType param is required for range searches, and it appears to correspond to the code in holdings 852 indicator 1 (though I have not tested this for other call number types).
The current release of the Excel plugin only do simple equivalence searches on a single index, but there is a beta version that supports multi-index searches and range searches. It is documented here:
https://github.com/pulibrary/ExcelAlmaLookup?tab=readme-ov-file#beta-version-v140-with-multi-index-searching
With the beta plugin, if you put the start of the range in column A, and the end of range in column B, you could build the query as follows:
image.png (view on web)<https://github.com/user-attachments/assets/a5202e30-b9e6-4ff3-aad7-0278eeeede37>
The third param is "alma.permanentCallNumberType", and you have to select "Other fields..." from the dropdown to get to the dialog where you can select it. This will perform the SRU query I specified above. However, it will only retrieve a maximum of 25 records, and all of the results will be placed in one cell separated by vertical bar characters. (Even the direct SRU query can only retrieve 50 records at a time, so you would have to page through the results if there are more records.)
This approach may not be practical if there are a lot of records in your range, but if you decide to pursue it, let me know if you have any questions about how to apply it to your case. I hope you are able to find a workable solution!
Tom Ventimiglia
Princeton University Library
-
Reply to this email directly, view it on GitHub<#35 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ABL4QMBQLUGGYPJCYFA4QNT3VU66BAVCNFSM6AAAAACIBSNUQWVHI2DSMVQWIX3LMV43URDJONRXK43TNFXW4Q3PNVWWK3TUHMYTINJXGUZDGNY>.
You are receiving this because you authored the thread.Message ID: ***@***.******@***.***>>
…________________________________
"The contents of this e-mail (including any attachments) may be confidential and/or subject to copyright. Any unauthorised use, distribution, or copying of the contents is expressly prohibited. If you have received this e-mail in error, please advise the sender by return e-mail or telephone and then delete this e-mail together with all attachments from your system."
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment

Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
This is a really great tool that we are already putting to good use. Thank you!!!
We have a use case where we want to retrieve the barcodes of all items between two call numbers so we can bulk update item details, using the "Item updater by Excel" cloud app, to reflect a move to storage. Ideally, we'd scan the first and last barcodes of the range, retrieve the call numbers and then retrieve the barcodes of items in between those two call numbers. Not sure this can be done programmatically with your tool (we're now investigating APIs), but we'd be interested in any comments or ideas.
Regards,
Craig.
Beta Was this translation helpful? Give feedback.
All reactions