You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Anshuman Singh <si...@gmail.com> on 2020/05/11 06:14:51 UTC

Why Solr query time is more in case the searched value frequency is more even if no sorting is applied, for the same number of rows?

Suppose I have two phone numbers P1 and P2 and the number of records with
P1 are X and with P2 are 2X (2 times X) respectively. If I query for R rows
for P1 and P2, the QTime in case of P2 is more. I am not specifying any
sort parameter and the number of rows I'm asking for is same in both the
cases so why such difference?

I understand that if I use sorting on some basis then it has to go through
all the documents and then apply sorting on them before providing the
requested rows. But without sorting can't it just read the first R
documents from the index? In this case, I believe the QTime will not depend
on the total number of documents with respect to the query but on the
requested number of rows.

Re: Why Solr query time is more in case the searched value frequency is more even if no sorting is applied, for the same number of rows?

Posted by Paras Lehana <pa...@indiamart.com.INVALID>.
Well, in a way, QTime can depend on the total number of terms existing in
the core.

It would have been better if you had posted sample query and analysis
chain.

On Mon, 11 May 2020 at 11:45, Anshuman Singh <si...@gmail.com>
wrote:

> Suppose I have two phone numbers P1 and P2 and the number of records with
> P1 are X and with P2 are 2X (2 times X) respectively. If I query for R rows
> for P1 and P2, the QTime in case of P2 is more. I am not specifying any
> sort parameter and the number of rows I'm asking for is same in both the
> cases so why such difference?
>
> I understand that if I use sorting on some basis then it has to go through
> all the documents and then apply sorting on them before providing the
> requested rows. But without sorting can't it just read the first R
> documents from the index? In this case, I believe the QTime will not depend
> on the total number of documents with respect to the query but on the
> requested number of rows.
>


-- 
-- 
Regards,

*Paras Lehana* [65871]
Development Engineer, *Auto-Suggest*,
IndiaMART InterMESH Ltd,

11th Floor, Tower 2, Assotech Business Cresterra,
Plot No. 22, Sector 135, Noida, Uttar Pradesh, India 201305

Mob.: +91-9560911996
Work: 0120-4056700 | Extn:
*1196*

-- 
*
*

 <https://www.facebook.com/IndiaMART/videos/578196442936091/>