Closed webjay closed 12 years ago
Hi @dalia-m-elsayed
What should I set offset to?
@dalia-m-elsayed Could you explain how I can use sinceId and offset?
If I understand it correctly, sinceId can be used to get id's larger than sinceId, but text and photos don't share the same ids, so I guess we need a sinceId_text and sinceId_photos etc?
How is offset used?
Hi Jacob,
Actually sinceId is simply a unix timestamp, not and actual ID, so, for example, in the first time you run the request for a certain event, you use strtotime([event_start_date]), so this will fetch all the buzz created since the event start date. then, you save the [current timestamp], and then the next time you run the request you'll use the saved [current timestamp], so you'll get the buzz created since that timestamp, and so on so we don't miss a buzz entry....
as for the limit and the offset, you can use them in this way : for the same request that you've done with the sinceId, you can optionally use a limit and offset params, how ? to get the buzz created since a certain timestamp, but you need to split the request to more than one request to limit the returned data, so use : request1: sinceId, limit=50, offset 0 request2: same_sinceId, limit=50, offset 50 request3: same_sinceId, limit=50, offset 100 and so on..
Does that make sense ?
On Fri, Jun 22, 2012 at 2:59 PM, Jacob Friis Saxberg < reply@reply.github.com
wrote:
@dalia-m-elsayed Could you explain how I can use sinceId and offset?
If I understand it correctly, sinceId can be used to get id's larger than sinceId, but text and photos don't share the same ids, so I guess we need a sinceId_text and sinceId_photos etc?
How is offset used?
Reply to this email directly or view it on GitHub: https://github.com/webjay/rf12/issues/1#issuecomment-6506999
Dalia El-Sayed
Reason: offset should not be since_id
Find out what offset should be.