I import data from database directly into the solr index. Now I want to search it using php-solr-client. Now I want to search it:
$offset = 0;
$limit = 10;
$queries = array(
'details:Server'
);
$response = $solr->search( $query, $offset, $limit );
For now I can only search when I specify the field, e.g. details. Is there a way to search all fields at a time?
If you omit the
details:, doesn’t it search all fields that are indexed?Otherwise, you can always combine multiple fields in one query like this:
details:Server OR field2:Server OR field3:ServerEDIT: Regarding default field to search, specify a “dummy” field that would be populated with multiple values:
Then have copyField entries for all fields that would be searched:
And finally, specify that this field should be the default one:
That should work.