php - Solr: Check if a document exists without retrieving the document -


i need find out if document exists documents saved in solr server pretty big if classic search retrieve document specified id , document returned takes time process. there possibility return example number of matching documents without retrieving actual documents ?

yes, possible. can set rows=0 when submitting query, execute it. no actual documents returned.

in response, can read numfound attribute response. if numfound=1 (since id), document found.


Comments

Popular posts from this blog

All overlapping substrings matching a java regex -

c++ - Using OpenSSL in a multi-threaded application -

php - Deleting/Renaming a locked file -