Re: Using the NOT operator with the AND operator

2025-01-23 Thread Mikhail Khludnev
Right. Also it can be expressed with q=+attribute2:Document
-attribute1:there

On Wed, Jan 22, 2025 at 7:10 PM Rahul Goswami  wrote:

> This is one of the idiosyncrasies of the NOT boolean operator. I prefer
> using the "-" operator for boolean NOT
> <
> https://solr.apache.org/guide/solr/latest/query-guide/standard-query-parser.html#the-boolean-operator-2
> >.
> The way to see it is that it behaves like a set operation where you give
> Solr a result set and then subtract what you DON'T want. The below query
> should work for you:
>
> http://host:8983/solr/solr1/select?q=(*:* -(
>  attribute1:there)) AND
> (attribute2:Document)
>
> So you are basically telling Solr to consider results from the
> MatchAllDocsQuery (*:*) and subtracting the results for (attribute1:there)
>
> -Rahul
>
> On Wed, Jan 22, 2025 at 10:51 AM Farmerie, Henry
>  wrote:
>
> > Hello,
> >  I'm using Solr 9.7.0, and I observe the following query returns zero
> > results:
> >
> > http://host:8983/solr/solr1/select?q=(NOT( attribute1:there)) AND
> > (attribute2:Document)<
> >
> http://host:8983/solr/solr1/select?q=(NOT(%20attribute1:there))%20AND%20(attribute2:Document)
> > >
> >
> > However, if I do the search criteria on each side of the "AND"
> separately,
> > I get results back, and they match:
> >
> > http://host:8983/solr/solr1/select?q=(NOT( attribute1:there))
> > http://host:8983/solr/solr1/select?q=(attribute2:Document)
> >
> > Conversely, if I have a query that omits the NOT operator for the
> criteria
> > on the left side of the AND operator, it works as expected and returns
> > results:
> >
> > http://host:8983/solr/solr1/select?q=( attribute1:truevalue) AND
> > (attribute2:Document)<
> >
> http://host:8983/solr/solr1/select?q=(%20attribute1:truevalue)%20AND%20(attribute2:Document)
> > >
> >
> > So it appears that using the NOT operator as part of the criteria used
> > when AND'ed with another criteria, "breaks" the query.
> >
> > Has anyone else seen this behavior, and if so, is there a way to make it
> > work?
> >
> > -Henry Farmerie
> >
> >
> >
>


-- 
Sincerely yours
Mikhail Khludnev


Re: Re: Vector search problems SolR 9.6 (Lucene 9.10) vs. SolR 9.7 (Lucene 9.11)

2025-01-23 Thread David Smiley
Hi Andreas,

The test org.apache.solr.CursorPagingTest is a single-core test for
cursorMark.  Alternatively, perhaps you might want to modify a KNN query
test like org.apache.solr.search.neural.KnnQParserTest.

BTW, the correct capitalization of "Solr" is as I typed it, not as you are
typing it.

~ David

On Wed, Jan 22, 2025 at 3:31 AM Moll, Dr. Andreas 
wrote:

> Hi,
>
>
>
> I was aware of the fact, that the tie breaker "sort by id" would only
> effect the search after the results of the KNN algorithm come in (which may
> be non-deterministic), but I guessed it to be a best practice to add it to
> all queries since e.g. searching with a cursor mark requires the tie
> breaker.
>
>
>
> I already checked the SolR 9.8 RC1 and the error is still present.
>
>
>
> If you pinpoint me to a SolR Test that could be adapted to check for the
> problem, I can try to setup a new test.
>
>
>
>
>
> Best regards
>
>
>
> Andreas Moll
>
>
>


[ANNOUNCE] Apache Solr 9.8.0 released

2025-01-23 Thread Anshum Gupta
23 January 2025,  Apache Solr™ 9.8.0 available

The Solr PMC is pleased to announce the release of Apache Solr 9.8.0.

Solr is the blazing-fast, open source, multi-modal search platform built on
Apache Lucene. It powers full-text, vector, analytics, and geospatial
search at many of the world's largest organizations. Other major features
include Kubernetes and docker integration, streaming, highlighting,
faceting, and spell checking.

The release is available for immediate download at:

https://solr.apache.org/downloads.html
Solr 9.8.0 Release Highlights

   - The Solr Cross-DC Project has graduated from the sandbox repository
   into the Solr project as a supported capability.
   -

   Requests can specify the 'memAllowed' parameter to halt requests that
   have exceeded this amount of memory (similar to timeAllowed but for memory).
   -

   New knn_text_to_vector query parser that encodes query text into a
   vector (AKA "embedding") via external LLM services.
   -

   New ParallelHttpShardHandlerFactory for reducing distributed-search
   latency in collections with many shards. This is not used by default.
   - Cluster properties can now be listed or read individually using new v2
   APIs ("GET /api/cluster/properties" and "GET
   /api/cluster/properties/propName")
   - SolrJ CloudSolrClient now performs reasonably when configured with
   Solr URLs, which is increasingly going to be preferred over ZK URLs.  Some
   big performance improvements occurred this release.
   - Shard splits now support indexes with nested documents.
   - "" tags in solrconfig.xml are now quietly ignored by default
   unless explicitly enabled with the `SOLR_CONFIG_LIB_ENABLED=true`
   environment variable (or corresponding sysprop)
   - multiThreaded=true no longer risks rejected exceptions under load.
   But you may need to increase the thread pool to more fully utilize a
   machine than previously.

Please refer to the Upgrade Notes in the Solr Ref Guide for information on
upgrading from previous Solr versions:

https://github.com/apache/solr/blob/main/solr/solr-ref-guide/modules/upgrade-notes/pages/major-changes-in-solr-9.adoc#solr-98

Please read CHANGES.txt for a full list of new features, changes and
bug-fixes:

https://solr.apache.org/docs/9_8_0/changes/Changes.html
Thanks to all contributors:

David Smiley, Eric Pugh, Jason Gerlowski, Houston Putman, Sanjay Dutt,
Andrzej Bialecki, Christos Malliaridis, Aparna Suresh, Pierre Salagnac, Gus
Heck, hossman, Rahul Goswami, Jan Høydahl, Bruno Roustant, Uwe Schindler,
Mark Miller, Alessandro Benedetti, Tim Owens, Carlos Ugarte, Matthew
Biscocho, shalin, Paul McArthur, Mathieu Marie, Haythem Khiri, James Dyer,
Zack Kendall, Shawn Heisey, Stephen Zhou, Christine Poerschke, Alexander
Zagniotov, Martin Anzinger, Peter Kroiss, Andrey Bozhko, Anshum Gupta