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 Luis Lebolo <lu...@gmail.com> on 2013/03/27 22:08:44 UTC

Query on all dynamic fields or wildcard field query

Hi All,

First I have to apologize and admit that I'm asking this question before
doing any real research =( Was hoping for some preliminary help before I
start this endeavor tomorrow. So here goes:

Can I query for a value in multiple (wildcarded) fields?

For example, if I have dynamic fields fieldName_someToken (e.g.
fieldName_1, fieldName_2, fieldName_3), can I construct a query like
fieldName_*:someValue?

The query itself doesn't work, but is there a way to query numerous dynamic
fields without explicitly listing them?

Thanks,
Luis

Re: Query on all dynamic fields or wildcard field query

Posted by Jack Krupansky <ja...@basetechnology.com>.
No, but you can use the dismax feature of the dismax and edismax query 
parsers to specify a static list of any number of fields to be searched for 
terms in a query that do not have an explicit field specified.

And, no harm filing a Jira to request support for a wildcard field search 
feature.

-- Jack Krupansky

-----Original Message----- 
From: Luis Lebolo
Sent: Wednesday, March 27, 2013 5:08 PM
To: solr-user
Subject: Query on all dynamic fields or wildcard field query

Hi All,

First I have to apologize and admit that I'm asking this question before
doing any real research =( Was hoping for some preliminary help before I
start this endeavor tomorrow. So here goes:

Can I query for a value in multiple (wildcarded) fields?

For example, if I have dynamic fields fieldName_someToken (e.g.
fieldName_1, fieldName_2, fieldName_3), can I construct a query like
fieldName_*:someValue?

The query itself doesn't work, but is there a way to query numerous dynamic
fields without explicitly listing them?

Thanks,
Luis