Click here to Skip to main content
15,887,954 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am querying a rest service using a httpwebrequest which by default limits the returned data to 100 records. I am using date parameters within the query and I also wish to increase the limit to 500 records.

The current working query:

The true query string is constructed using a class object and is json serialized. The sample is used to show the request content!

query =?where={"_createdAt":{"$gte":{"$date":"2014-11- 12T09:17:59.5894738Z"},"$lt":{"$date":"2014-11-20T09:17:59.5894738Z"}}}

request = DirectCast(WebRequest.Create("https://api.mydata.com/rest/1/db/collections/jobs" & query), HttpWebRequest)

how would i add the limit parameter to the existing query. I have tried simply appending the limit to the request which does not break the query but also it does not limit the results! How do you construct both elements the date delimiter and the limit?
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900