QueryResponse ordering

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

QueryResponse ordering

Srinivas Kashyap-3
Hello,

I have a scenario where I'm using filter query to fetch the results.

Example: Filter query(fq) - PARTY_ID:(abc OR def OR ghi)

Now I'm getting query response through solrJ in different order. Is there a way I can get the results in same order as specified in filter query?

Tried dismax boost bq parameter, but it is not returning any value. Please refere below url

http://localhost:8983/solr/party/select?bq=PARTY.PARTY_ID:"abc"^2+PARTY.PARTY_ID:"def"^1&defType=dismax&fq=PARTY.PARTY_ID:"abc<http://localhost:8983/solr/party/select?bq=PARTY.PARTY_ID:%22abc%22%5e2+PARTY.PARTY_ID:%22def%22%5e1&defType=dismax&fq=PARTY.PARTY_ID:%22abc>" OR PARTY.PARTY_ID:"def"&q=*:*

Thanks,
Srinivas
________________________________
DISCLAIMER:
E-mails and attachments from Bamboo Rose, LLC are confidential.
If you are not the intended recipient, please notify the sender immediately by replying to the e-mail, and then delete it without making copies or using it in any way.
No representation is made that this email or any attachments are free of viruses. Virus scanning is recommended and is the responsibility of the recipient.

Disclaimer

The information contained in this communication from the sender is confidential. It is intended solely for use by the recipient and others authorized to receive it. If you are not the recipient, you are hereby notified that any disclosure, copying, distribution or taking action in relation of the contents of this information is strictly prohibited and may be unlawful.

This email has been scanned for viruses and malware, and may have been automatically archived by Mimecast Ltd, an innovator in Software as a Service (SaaS) for business. Providing a safer and more useful place for your human generated data. Specializing in; Security, archiving and compliance. To find out more visit the Mimecast website.
Reply | Threaded
Open this post in threaded view
|

Re: QueryResponse ordering

Alessandro Benedetti
Hi Srinivas,
Filter queries don't impact scoring but only matching.
So, what is the ordering you are expecting?
A bq (boost query) parameter will add a clause to the query, impacting the
score in an additive way.
The query you posted is a bit confused, what was your intent there?
To boost search results having "abc" as the PARTY.PARTY.ID ?
https://lucene.apache.org/solr/guide/6_6/the-dismax-query-parser.html#TheDisMaxQueryParser-Thebq_BoostQuery_Parameter



-----
---------------
Alessandro Benedetti
Search Consultant, R&D Software Engineer, Director
Sease Ltd. - www.sease.io
--
Sent from: https://lucene.472066.n3.nabble.com/Solr-User-f472068.html
---------------
Alessandro Benedetti
Search Consultant, R&D Software Engineer, Director
Sease Ltd. - www.sease.io
Reply | Threaded
Open this post in threaded view
|

RE: QueryResponse ordering

Srinivas Kashyap-3
Hi Alessandro,

I'm trying to retrieve party id 'abc' 'def' 'ghi' in the same order I pass to filter query. Is this possible?

The sorting field which I want to get results is not in solr schema for party core. The sorting field Is outside solr. I want to able to fetch the QueryResponse(SolrJ) solrdocumentList sorted based on this sorting criteria.

Yes, I understand bosst parameter bq doesn't apply on filter queries. Is there an alternative?

Thanks,
Srinivas
From: Alessandro Benedetti <[hidden email]>
Sent: 14 January 2021 01:55
To: [hidden email]
Subject: Re: QueryResponse ordering

Hi Srinivas,
Filter queries don't impact scoring but only matching.
So, what is the ordering you are expecting?
A bq (boost query) parameter will add a clause to the query, impacting the
score in an additive way.
The query you posted is a bit confused, what was your intent there?
To boost search results having "abc" as the PARTY.PARTY.ID ?
https://lucene.apache.org/solr/guide/6_6/the-dismax-query-parser.html#TheDisMaxQueryParser-Thebq_BoostQuery_Parameter<https://lucene.apache.org/solr/guide/6_6/the-dismax-query-parser.html#TheDisMaxQueryParser-Thebq_BoostQuery_Parameter>



-----
---------------
Alessandro Benedetti
Search Consultant, R&D Software Engineer, Director
Sease Ltd. - www.sease.io<http://www.sease.io>
--
Sent from: https://lucene.472066.n3.nabble.com/Solr-User-f472068.html<https://lucene.472066.n3.nabble.com/Solr-User-f472068.html>
________________________________
DISCLAIMER:
E-mails and attachments from Bamboo Rose, LLC are confidential.
If you are not the intended recipient, please notify the sender immediately by replying to the e-mail, and then delete it without making copies or using it in any way.
No representation is made that this email or any attachments are free of viruses. Virus scanning is recommended and is the responsibility of the recipient.

Disclaimer

The information contained in this communication from the sender is confidential. It is intended solely for use by the recipient and others authorized to receive it. If you are not the recipient, you are hereby notified that any disclosure, copying, distribution or taking action in relation of the contents of this information is strictly prohibited and may be unlawful.

This email has been scanned for viruses and malware, and may have been automatically archived by Mimecast Ltd, an innovator in Software as a Service (SaaS) for business. Providing a safer and more useful place for your human generated data. Specializing in; Security, archiving and compliance. To find out more visit the Mimecast website.