Thanks, Demian and Alan!

Yes when I said browse I meant the alphabrowse module.  Since solr can't sort on multiple fields, we are considering pointing all of our call number searches to the browse module, and beefing up the browseable list to include more information (titles, at least).

The browse list would use the sort-normalized version of the call number (with all the padding zeroes), and a record would have multiple entries if it had multiple different call numbers.

At which point I have two options:
1.  Translate search queries into sort-normalized format to submit them.  Then translate each sort-normalized call number back into something that could be displayed before showing to the user.
2.  Store some sort of string-parsey quasi-tuple field, as I mentioned before, in order to be able to match a sort-normalized call number with the correct display value.  I think this option is better because it won't cost a huge amount of space and it will save time when presenting the site.  Also I wouldn't have to write all the code to translate the different types of call numbers back and forth.

Alan's method of just grabbing the first call number if obviously way easier than any of this.

Anna



On Wed, Feb 20, 2013 at 12:38 PM, Alan Rykhus <alan.rykhus@mnsu.edu> wrote:
Hello Anna,

Yes, we do.

But it is easier to make things work with only a single entry. So we
take just the first call number we find in our holding strings.

I'm not sure if you can crawl a multi-value index in Solr. That's what
is done to create the current Alphabetical browse databases.

I see Demian posted a response too. The newer version of the Alphabetic
browse uses a normailized call number index. If you can crawl the
multi-values, it could be done.

al

On Wed, 2013-02-20 at 12:03 -0500, anna headley wrote:
> Does anyone else have a situation where records could have multiple
> items with different call numbers?  For example the item is held in
> multiple libraries in the consortium, and each has given it a
> different call number, or the item is held in the general collection
> as well as some other collection with its own special set of call
> numbers.
>
>
> Are you just arbitrarily choosing one call number to use as the sort
> value?  This would mean the item would only show up in one place in
> the browse list.
>
> I'm thinking of adding another index field that holds a tuple of
> (sort, display) call number values so that I can match between them
> when needed.  (Well, it couldn't be an actual tuple, but some sort of
> parseable string.)
>
> Is anyone else doing something like this?  Something smarter than
> this?
>
> Thanks!
> Anna
>
>
>
>
>
> On Tue, Feb 19, 2013 at 8:38 PM, Tod Olson <tod@uchicago.edu> wrote:
>         I think that's attached to VUFIND-726:
>
>                 http://vufind.org/jira/browse/VUFIND-726
>
>         It looks like these changes would be of great use to my site,
>         especially the business of returning additional fields in the
>         browse search. I'd be interested in seeing these changes work
>         their way into the trunk. Could probably put some time into in
>         a few weeks. Is that of interest to you?
>
>         -Tod
>
>
>         On Feb 7, 2013, at 2:45 PM, Alan Rykhus <alan.rykhus@mnsu.edu>
>         wrote:
>
>         > Hello Anna,
>         >
>         > I was sure I posted a tarball to JIRA, but I can't find it.
>         oh well
>         >
>         > Here is a README of what I changed:
>         >
>         >
>         > What needs to be done to implement the new Alphabetic Browse
>         > functionality?
>         >
>         >     1. Indexing
>         >              * biblio/conf/schema.xml
>         >                      * change topic_browse and author_browse
>         to
>         >                        stored=true
>         >              * marc_local.properties
>         >                      * callnumber
>         >                              * uses getFullCallNumber from
>         >                                callnumber.bsh
>         >                              * This is for searching and is
>         the default
>         >                                as delivered in Vufind
>         >                      * callnumber-norm_str
>         >                              * uses
>         getFullCallNumberNormalized
>         >                                      * need to add to
>         callnumber.bsh
>         >                                      * uses
>         >
>          org.solrmarc.tools.CallNumUtils
>         >                                        function
>         >                      * callnumber_display_str
>         >                              * uses getFullCallNumberDisplay
>         >                                      * need to add to
>         callnumber.bsh
>         >                                      * same as
>         getFullCallNumber, just
>         >                                        do not strip spaces
>         >                                      * name needs to be a
>         '_', Smarty
>         >                                        does not like '-'s
>         >              * biblio/conf/solrconfig.xml
>         >                      * For the lcc configuration use
>         callnumber instead
>         >                        of callnumber-a
>         >     2. New jar files
>         >              * browse-indexing.jar
>         >                      * put in /srv/vufind/import
>         >              * browse-handler.jar
>         >                      * put in /srv/vufind/solr/lib
>         >     3. New sqlite build scripts
>         >              * Build all indexes using StoredFieldLeech
>         >              * I don't have auth library, don't know what
>         effect this
>         >                will have
>         >                      * topic_browse
>         >                      * author_browse
>         >              * callnumber instead callnumber-a
>         >                      * This is a full call number field
>         >              * callnumber-norm_str for sort field
>         >              * New parameter -Dbuildfield
>         >                      * This builds an additional field in
>         sqlite to
>         >                        allow limits to an institution
>         >                      * Can be omitted if you do not need a
>         limit
>         >     4. config.ini change
>         >              * new section [AlphaBrowse_Extras]
>         >                      * Allows you to retrieve additional
>         fields from
>         >                        database for display purposes
>         >                      * I use it to get the
>         callnumber_display_str and
>         >                        title fields for the call numbers
>         >     5. web/sys/Solr.php
>         >              * altered function alphabeticBrowse to handle
>         new
>         >                parameters
>         >     6. web/services/AlphaBrowse/Results.php
>         >              * Altered code to handle new config and page
>         parameters
>         >     7. web/interface/themes/mnpals/AlphaBrowse/home.tpl
>         >              * links are different
>         >                      * When browsing forward and back, the
>         rowid is in
>         >                        the link from the initial browse
>         >              * Additions to display extra fields
>         >     8. web/interface/themes/mnpals/css/styles.css
>         >              * added .alphaBrowseLCCHeading
>         >                and .alphaBrowseTitleHeading entries for
>         callnumber
>         >                table
>         >
>         > If you have more questions, let me know.
>         >
>         > al
>         >
>         >
>         > On Thu, 2013-02-07 at 14:53 -0500, anna headley wrote:
>         >> Hi Alan,
>         >>
>         >>
>         >> Any additional detail on what you did to accomplish this
>         would be
>         >> greatly appreciated.
>         >>
>         >>
>         >> Is all your work in AlphaBrowse?  Did you also create /
>         change
>         >> indexing rules?  How are you normalizing the user input?
>         >>
>         >>
>         >> We'd like to do this based on the browse functionality, as
>         well, and
>         >> then enhance that page to show more info about each item.
>         >>
>         >>
>         >> Anna
>         >>
>         >>
>         >>
>         >>
>         >> On Fri, Jan 11, 2013 at 9:43 AM, Alan Rykhus
>         <alan.rykhus@mnsu.edu>
>         >> wrote:
>         >>        Hello,
>         >>
>         >>        I've been working with Mark Triggs' AlphaBrowse code
>         and have
>         >>        the
>         >>        AlphaBrowse working for call numbers.
>         >>
>         >>        The one issue I'm having problems with is seeding
>         into the
>         >>        correct spot.
>         >>        I plan on looking at that next week. But the full
>         call numbers
>         >>        are
>         >>        sorting in order. I've added code to bring in any
>         additional
>         >>        fields you
>         >>        might want from the records. At this time I'm adding
>         the
>         >>        titles to the
>         >>        display in the browse screen.
>         >>
>         >>        Today I'm rebuilding my Solr db on a machine that
>         could use
>         >>        more memory.
>         >>        The indexing job will not finish until tomorrow or
>         Sunday.
>         >>        Monday I'll
>         >>        have my sites up where you can see this.
>         >>
>         >>        This won't allow you to search on a range, but you
>         can browse
>         >>        through
>         >>        the numbers.
>         >>
>         >>        al
>         >>
>         >>
>         >>        On Fri, 2013-01-11 at 11:34 +0000, Osullivan L.
>         wrote:
>         >>> Hi Tod,
>         >>>
>         >>> Apologies for the delay in  replying - I lost this e-mail
>         in
>         >>        the
>         >>> mountain of e-mails I had after the New Year.
>         >>>
>         >>> I have managed to get the items to display in the correct
>         >>        order with
>         >>> some custom indexing but I hit a snag with the ultimate
>         goal
>         >>        of my
>         >>> attempts which was to add call number range searching.
>         >>>
>         >>> getFullNormalizedLCCN.bsh
>         >>>
>         >>> import org.marc4j.marc.Record;
>         >>> import org.solrmarc.tools.CallNumUtils;
>         >>> org.solrmarc.index.SolrIndexer indexer = null;
>         >>>
>         >>> /**
>         >>> * Normalize a single LCCN
>         >>> * @param lccn
>         >>> * @return Normalized LCCN
>         >>> */
>         >>> public String getFullNormalizedLCCN(Record record, String
>         >>        lccn) {
>         >>>
>         >>>    if (lccn != null) {
>         >>>
>         >>>        lccn = indexer.getFirstFieldVal(record, lccn);
>         >>>
>         >>>        String recordID = "1"; // Need to assign real value
>         >>        from
>         >>> record?
>         >>>
>         >>>    if (lccn != null) {
>         >>>
>         >>>        String normal = CallNumUtils.getLCShelfkey(lccn,
>         >>        recordID);
>         >>>
>         >>>        if (normal != null) {
>         >>>            // Send back normalized LCCN:
>         >>>            return normal;
>         >>>        }
>         >>>    }
>         >>>    }
>         >>>
>         >>>    // If we got this far, we couldn't find a valid value:
>         >>>    return null;
>         >>> }
>         >>>
>         >>> marc_local.properties
>         >>> callnumber-norm_str=  script(getFullNormalizedLCCN.bsh),
>         >>> getFullNormalizedLCCN(852hi)
>         >>>
>         >>> schema.xml
>         >>> <field name="callnumber-search" type="string"
>         indexed="true"
>         >>> stored="true"/>
>         >>>
>         >>> searches.ini
>         >>> [Sorting]
>         >>> ; Use the "callnumber" line for LC or the "dewey-sort"
>         line
>         >>        for Dewey
>         >>> Decimal.
>         >>> ; If you want to enable both systems for sorting, you can
>         >>        uncomment
>         >>> both lines,
>         >>> ; but you will need to add some custom text to distinguish
>         >>        between the
>         >>> two.
>         >>> callnumber-norm_str = sort_callnumber
>         >>>
>         >>> [DefaultSortingByType]
>         >>> CallNumber = callnumber-norm_str
>         >>>
>         >>> Cheers,
>         >>>
>         >>> Luke
>         >>>
>         >>> On 12/27/2012 02:36 PM, Tod Olson wrote:
>         >>>
>         >>>> Luke,
>         >>>>
>         >>>> Did you ever come up with a solution to this problem?
>         >>>>
>         >>>> We're in a similar way, wanting the call number browse to
>         >>        reflect call number shelving order.
>         >>>>
>         >>>> -Tod
>         >>>>
>         >>>> On May 21, 2012, at 8:22 AM, Osullivan L.
>         >>        <L.Osullivan@swansea.ac.uk> wrote:
>         >>>>
>         >>>>> Hi Folks,
>         >>>>>
>         >>>>> One of our subject librarians has asked us to change the
>         >>        way results are displayed when a callnumber search
>         is
>         >>        performed.
>         >>>>>
>         >>>>> Basically, if someone searches for PQ239, she would like
>         >>        the results returned to be PQ239, PQ239 > ABC,
>         PQ239 .A22
>         >>        2011, PQ239 .W55 2011, PQ240, PQ2390 etc
>         >>>>>
>         >>>>> At present, we are getting a lot of PQ2391, PQ2392 etc
>         >>        at the top of our results...
>         >>>>>
>         >>>>> The problem I see it two fold - To get what she ideally
>         >>        wants, we'd need to restrict all callnumber search
>         to exact
>         >>        matches using the callnumber-a field and then create
>         more
>         >>        fields to provide sorting for the rest of the
>         callnumber. Has
>         >>        anyone done something similar?
>         >>>>>
>         >>>>> Thanks,
>         >>>>>
>         >>>>> Luke
>         >>>>>
>         >>
>          ------------------------------------------------------------------------------
>         >>>>> Live Security Virtual Conference
>         >>>>> Exclusive live event will cover all the ways today's
>         >>        security and
>         >>>>> threat landscape has changed and how IT managers can
>         >>        respond. Discussions
>         >>>>> will include endpoint security, mobile security and the
>         >>        latest in malware
>         >>>>> threats.
>         >>
>          http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
>         >>>>> _______________________________________________
>         >>>>> VuFind-General mailing list
>         >>>>> VuFind-General@lists.sourceforge.net
>         >>>>>
>         >>
>          https://lists.sourceforge.net/lists/listinfo/vufind-general
>         >>>
>         >>> --
>         >>> Luke O'Sullivan
>         >>> Systems Developer
>         >>> Web Team
>         >>> Swansea University, Singleton Park, Swansea SA2 8PP, UK
>         >>> l.osullivan@swansea.ac.uk
>         >>> 01792 602772
>         >>> @l_os_cymru
>         >>
>         >>>
>         >>
>          ------------------------------------------------------------------------------
>         >>> Master HTML5, CSS3, ASP.NET, MVC, AJAX, Knockout.js, Web
>         API
>         >>        and
>         >>> much more. Get web development skills now with LearnDevNow
>         -
>         >>> 350+ hours of step-by-step video tutorials by Microsoft
>         MVPs
>         >>        and experts.
>         >>> SALE $99.99 this month only -- learn more at:
>         >>> http://p.sf.net/sfu/learnmore_122812
>         >>
>         >>> _______________________________________________
>         >>> Vufind-tech mailing list
>         >>> Vufind-tech@lists.sourceforge.net
>         >>> https://lists.sourceforge.net/lists/listinfo/vufind-tech
>         >>
>         >>
>         >>        --
>         >>        Alan Rykhus
>         >>        PALS, A Program of the Minnesota State Colleges and
>         >>        Universities
>         >>        (507)389-1975
>         >>        alan.rykhus@mnsu.edu
>         >>        "It's hard to lead a cavalry charge if you think you
>         look
>         >>        funny on a
>         >>        horse" ~ Adlai Stevenson
>         >>
>         >>
>         >>
>          ------------------------------------------------------------------------------
>         >>        Master HTML5, CSS3, ASP.NET, MVC, AJAX, Knockout.js,
>         Web API
>         >>        and
>         >>        much more. Get web development skills now with
>         LearnDevNow -
>         >>        350+ hours of step-by-step video tutorials by
>         Microsoft MVPs
>         >>        and experts.
>         >>        SALE $99.99 this month only -- learn more at:
>         >>        http://p.sf.net/sfu/learnmore_122812
>         >>
>         >>        _______________________________________________
>         >>        Vufind-tech mailing list
>         >>        Vufind-tech@lists.sourceforge.net
>         >>
>          https://lists.sourceforge.net/lists/listinfo/vufind-tech
>         >>
>         >>
>         >>
>         >
>         > --
>         > Alan Rykhus
>         > PALS, A Program of the Minnesota State Colleges and
>         Universities
>         > (507)389-1975
>         > alan.rykhus@mnsu.edu
>         > "Be pleasant until ten o'clock in the morning and the rest
>         of the day
>         > will take care of itself." ~ Elbert Hubbard
>         >
>         >
>         >
>         ------------------------------------------------------------------------------
>         > Free Next-Gen Firewall Hardware Offer
>         > Buy your Sophos next-gen firewall before the end March 2013
>         > and get the hardware for free! Learn more.
>         > http://p.sf.net/sfu/sophos-d2d-feb
>         > _______________________________________________
>         > Vufind-tech mailing list
>         > Vufind-tech@lists.sourceforge.net
>         > https://lists.sourceforge.net/lists/listinfo/vufind-tech
>
>
>
>         ------------------------------------------------------------------------------
>         Everyone hates slow websites. So do we.
>         Make your web apps faster with AppDynamics
>         Download AppDynamics Lite for free today:
>         http://p.sf.net/sfu/appdyn_d2d_feb
>         _______________________________________________
>         Vufind-tech mailing list
>         Vufind-tech@lists.sourceforge.net
>         https://lists.sourceforge.net/lists/listinfo/vufind-tech
>
>
>
> ------------------------------------------------------------------------------
> Everyone hates slow websites. So do we.
> Make your web apps faster with AppDynamics
> Download AppDynamics Lite for free today:
> http://p.sf.net/sfu/appdyn_d2d_feb
> _______________________________________________
> Vufind-tech mailing list
> Vufind-tech@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/vufind-tech

--
Alan Rykhus
PALS, A Program of the Minnesota State Colleges and Universities
(507)389-1975
alan.rykhus@mnsu.edu
"Be pleasant until ten o'clock in the morning and the rest of the day
will take care of itself." ~ Elbert Hubbard


------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_feb
_______________________________________________
Vufind-tech mailing list
Vufind-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/vufind-tech