Tech Blog

How to configure SRU and structure SRU retrieval queries

The only required configuration for the institution to use SRU is to define an SRU integration profile. For information regarding the profile see:

See:

Here is an SRU profile:

Once the integration profile is set up it can be used.  No other configuration is required.

The base URL for SRU requests is:

  • https://<Alma domain>/view/sru/<institution code>

For example if the Alma URL is:

Then the base URL for SRU requests is:

Search Syntax Example One

This is the syntax to search all fields for text “history”:

  • https://Alma domain/view/sru/institution_code?version=1.2&operation=searchRetrieve&recordSchema=marcxml&query=alma.all_for_ui=history

In our institution the syntax to search all fields for text “history” is:

Search Syntax Example Two

Searching for ISBN 9780385349949 would be as follows:

 The full list of possible search indexes can be retrieved as follows:

The possible indexes appear in the name set:

For example we see above that there is an option to search by other_system_number

So …

Search Syntax Example Three

Since this is the syntax to search by ISBN 9780385349949:

Search Syntax Example Four

This is the syntax to search by other system number (OCoLC)813526963

Note that in this example the other system number does not have a dash or underline and thus one equals sign is used in the URL.

The next example after this will have a dash or underline

Here is the beginning of the record

Here is the other_system_number

Search Syntax Example Five

This is the syntax to search by other system number  (YILIS_YLK)2020-02-20

Note that in this example the other system number does have a dash or underline and thus two equals signs are used in the URL.

This is the part of the URL with two equals signs:  query=alma.other_system_number==(YILIS_YLK)2020-02-20

  • http://eu00.alma.exlibrisgroup.com/view/sru/EXLDEV1_INST?version=1.2&operation=searchRetrieve&recordSchema=marcxml&query=alma.other_system_number==(YILIS_YLK)2020-02-20

Here is the beginning of the record

Here is the other_system_number

 

2 Replies to “How to configure SRU and structure SRU retrieval queries”

  1. Hello – I see that I can specify a record schema other than MARC (e.g. dc) and if I do that I get the record that has been mapped from MARC to DC. I imagine that’s done using a stylesheet. Where do I find and edit that stylesheet?

    Thanks!
    ~Teresa Soleau

Leave a Reply