php - How to search whole solr index? -
I import the data from the database directly into the SLOR index. Now I want to search using it. Now I want to find it:
$ offset = 0; $ Range = 10; $ Queries = array ('details: server'); $ Response = $ solr- & gt; Search ($ query, $ offset, $ range); For now I can only search when specifying fields, e.g. Details . Is there a way to find all the areas at one time?
If you leave the details: , will it be all the fields Does not find indexed? Otherwise, you can always add several fields in a query like this: Description: Server or Field 2: Server or Field 3: Server Edit: Regarding the default field to search, specify a "dummy" field that will be populated with multiple values:
& lt; Field Name = "Text" type = "text" indexed = "true" stored = "false" multidimensional = "true" /> Then there are copyfielded entries for all fields that will be searched :
& copy; CopyField source = "title" dest = "text" / & gt; & Lt; CopyField source = "akatitle" dest = "text" /> & Lt; CopyField source = "year" dest = "text" /> And finally, specify that this field should be the default:
& lt; DefaultSearchField & gt; Text & lt; / DefaultSearchField & gt; It should work.
Comments
Post a Comment