Forum Discussion

Abhinav47's avatar
Abhinav47
Copper Contributor
Aug 23, 2023

Pagination in Advanced Hunting Query

Hi,

I was trying to use the below query to fetch identityInfo

{
"Query": "IdentityInfo | limit 300000"
}

but as it doesnt have timestamp in it i was not able to get more than 100000 records and it has around 300000 records is there and is there any pagination mechanism that i can use to get the remaning records

  • jbmartin6's avatar
    jbmartin6
    Iron Contributor
    I don't think there is a built in pagination method in kusto/AH. I knew there was a limit on query returns and I always assumed there was a pagination option, but looking around now it seems there isn't. The advice I found generally revolved around determining subqueries. For instance, if you really wanted to get the whole identity info table (and not get the data from some more suitable source) I guess you split it up by first letter/number of some field, and just query through all the possibilities and add the results together. Or you could order by some field such as SID or object id, use take to just get the first 10k results, then look at the highest value you got back, then query again for values higher than that in the next round.

Resources