All times are UTC - 6 hours [ DST ]




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: Total count of records of query
PostPosted: Mon Mar 13, 2017 8:06 pm 
Offline
jtthomas10 - FlightAware user avatar

Joined: Sun Mar 12, 2017 1:44 pm
Posts: 1
First time poster here, so I apologize if I've misinterpreted some things.

I get that a query will return 15 records by default, and that is configurable via setting the howmany in combo with a call to SetMaximumResultsSize.

I have question then.

Is there a way to know the total number of records my query in total has so I know how many times to loop through in case my howmany/SMRS isn't big enough?

For example, if I call to get all of American's flights out of Chicago for a day, and I leave the default at 15.

How can I know how many times do I need to keep calling back to get the entire data set? Or, do I just keep looping through until my nextOffset is the same as the last one?

Sorry if this is a noob question.

Thanks,
Jeff


Top
 Profile  
 
 Post subject: Re: Total count of records of query
PostPosted: Mon Mar 13, 2017 9:41 pm 
Offline
mduell - FlightAware user avatar

Joined: Wed Jul 27, 2005 3:00 pm
Posts: 5103
Location: FAWHQ
Keep going until you don't get 15 or you hit your date/time limit.


Top
 Profile  
 
 Post subject: Re: Total count of records of query
PostPosted: Fri Mar 17, 2017 10:16 am 
Offline
FlightAware Staff
bovineone - FlightAware user avatar

Joined: Wed Jul 27, 2005 3:00 am
Posts: 1421
Location: FlightAware WHQ
Keep going until you get a nextOffset of -1 or you hit your date/time limit.

(You may sometimes get a result count less than 15 for a single page, due to encountering blocked or inaccessible flights.)


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC - 6 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to: