Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 820447
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T02:28:30+00:00 2026-05-15T02:28:30+00:00

I have within my SOLR index song objects which belong to a higher level

  • 0

I have within my SOLR index song objects which belong to a higher level album object. An example is shown below:

<song>
<album title>Blood Sugar Sex Magic</album title>
<song title>Under the Bridge</song title>
<description>A sad song about junkies</description>
</song>

What I can do at the moment is create a facet on the album title so that a search on songs will also show me what albums contain hits for that keyword.

The default behaviour for SOLR is that the facets are shown in the order of most hits to least. However what I want to achieve is the facet list to be sorted according to the relevancy of the top hit for that album.

For example a search on the word “sad” may show a facet with one hit for “Blood Sugar Sex Magic” and there may also be an album called “Sad Clown songs” where there are 10 hits. “Sad clown songs” will show as the first facet even though it may be that “Under the bridge” comes up as the most relevant song.

My question is how can I get all the facets back but then have them ordered by the relevancy of the songs within them? If I would need to change or extend some underlying SOLR code what would that be?

Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T02:28:31+00:00Added an answer on May 15, 2026 at 2:28 am

    Solr can only sort facets in lexicographical order or by count (see the facet.sort parameter).

    If you want to implement a different sort order I’d start in the SimpleFacets class.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a Solr index with a year field, I can query all results
I have links within my footer, which when they are clicked, reveal hidden content.
I am not sure if this is possible...i have code within my application which
I have written a script that gets data from solr for which date is
below is the json sample i have imported to solr where id is unique
I have the following task: Query SOLR and return a weighted list based on
I'm trying to assign a class that I have within the jQuery UI accordion
I have links within an iframe that are external, and I would like them
Within my application I have 20 or so ViewControllers and Xibs that the user
I have xml wherein i have xml within it again, like: <?xml version=\1.0\ encoding=\UTF-8\?>

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.