Questions tagged [query-parser]

69 questions
1
vote
1 answer

Make a GitHub-like file finder using Lucene

I have to make a file finder using Lucene. I thought of using wild card query. Text in a document: lucene/queryparser/docs/xml/img/plus.gif Search string: lqdocspg It should find: lucene/queryparser/docs/xml/img/plus.gif (it is the olny document for…
1
vote
0 answers

solr query parser with mininmum match on one field and exact match on other field

A csv file has been indexed in solr(8.9) with field as food, color and other fields. Both food and color fields have fieldType : text_general with multivalued as false. i want to retrieve result from solr index with 'food' field as minimum match of…
user752590
  • 111
  • 5
  • 12
  • 29
1
vote
1 answer

org.apache.lucene.queryparser.classic.ParseException: Cannot parse

I'm developing my own service based on Apache Lucene. This is a spring server, on the endpoint of which the search request comes - the fields to search for, and their values. This query needs to be parsed in Apache Lucene query, and then sent to the…
Viktor
  • 41
  • 5
1
vote
1 answer

Creating a cumulative sum column with_order in R

I'm working alongside a SQL tutorial using queryparser and tidyquery in R. This has been going well until I was asked to do: SELECT ... SUM(new_vaccinations) OVER (PARTITION BY location) as vaccinations_to_date Tidyquery reported that it did not…
1
vote
1 answer

Edismax query not working after migrating to solr 7.7 from 6.6

I have migrated to solr version 7.7 from 6.6 But after migrating to this version my edismax query is not working and returning 0 values. My edismax query is something like this. {!edismax qf='title' mm=1 k='("messi"^4.02 "ronaldinho"^2.01)'…
1
vote
0 answers

Change SQL query with a parametric query in Oracle

We have an application that uses a framework that we don't have access to it's java classes. I can just see the .class file in byte-code format. So I can't override that class. At that class we have a native query like below: "Select col1 from…
1
vote
0 answers

CustomQueryParser not retrieving correct documents?

I have designed my CustomQueryParser using OpenNLP to transform the query such that it would only contain terms with POS tags 'JJ', 'NNS' and 'NN'. Example Query = This is why all the hewlett packard and test Query after CustomerQueryParser =…
1
vote
0 answers

Search multi word phrase with wild cards in lucene

Using the following code block: public void MultiField(string fieldValue, string[] fieldList) { List occurs = new List(); foreach (string field in fieldList) { occurs.Add(Occur.SHOULD); …
Adamon
  • 484
  • 9
  • 21
1
vote
5 answers

Parse a SQL statement to see if it is anything other then a SELECT statement?

Is there a good way to parse a SQL statement to ensure it contains only a SELECT statement and nothing else? I am using C#, System.Data.SqlConnection, and MS SQL Server
Rachel
  • 130,264
  • 66
  • 304
  • 490
1
vote
1 answer

Do (or should) Search Engines Analyze Queries in Quotes?

When a user enters a search term in quotes, should the search engine search what is within the quotes exactly, or should it perform some analysis on the query like a query without quotes? For example, should the query "U.S. of America" match US of…
speedplane
  • 15,673
  • 16
  • 86
  • 138
1
vote
0 answers

Parse search queries in sql 2005 FTS

In lucene, we can use QueryParser.Parse(query) to find out how the given query is interpreted by lucene. Its very helpful. I am looking for some kind of API or build in sys functions to identify how the FTS parses given search string. I found…
RameshVel
  • 64,778
  • 30
  • 169
  • 213
1
vote
1 answer

Lucene NOT_ANALYZED not working with uppercase characters

I have build an index using a StandardAnalyzer, in this index are a few fields. For example purposes, imagine it has Id and Type. Both are NON_ANALYZED, meaning you can only search for them as-is. There are a few entries in my index: {Id: "1",…
Lennard Fonteijn
  • 2,561
  • 2
  • 24
  • 39
1
vote
1 answer

Lucene MultiFieldQueryParser and Highlighter

I am indexing articles in lucene index through different fields i.e. title, description, link, publishDate I query the index using MultiFieldQueryParser like +(title:[text]^5.0 description:[text]^4.0 link:[text]^3.0) +publishDate:[20150101 TO…
1
vote
0 answers

MYSQL: Intermediate query results

Is it possible to access the intermediate results generated by mysql during execution of a query?? Creating a view for the query stores the results of the query, i need to store the intermediate results of the every query for further query…
Ashwini
  • 91
  • 8
1
vote
2 answers

Lucene query parser not parse field as expected

I want to parse a simple query using lucene (3.0.3): title:(+return +"pink panther") Just like in the documentation example. The expected result is: +title:return +title:"pink panther" But instead i get: +title:return +title:"itle return pink…
Omri
  • 887
  • 8
  • 24