We will query the TotalOrdersPerCustomer
index from the Orders
database which we created in the previous chapter. You will use the RESTClient tool to send the request to RavenDB and view the server response and analyze it:
Launch the RESTClient tool.
Click on the Method tab and select the GET HTTP method.
In the HTTP Request section, enter this URL:
http://localhost:8080/databases/orders/indexes/TotalOrdersPerCustomer
.Click on the green Go! button to send the
GET
request to the server.
We queried the TotalOrdersPerCustomer
index from the Orders
database using a GET
request addressed to the indexes
structure.
The server response is a JSON object that contains the arrays: Results
which contains all returned documents by the index and Includes
. Also, in the server response, we have two fields: IsStale
the value of which is false
and the TotalResults
the value of which is set to 4
which is the documents count that have been returned by the...