You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I couldn't figure out how to start iterating items from specific position. If I have a huge json file and at some point something goes wrong, how to continue process from some position without need to iterate from the beginning for many hours again? Many thanks!
The text was updated successfully, but these errors were encountered:
There's no built-in option for this. However, it should be possible to open a stream (file), use fseek() to get to the desired position, and then pass the stream to JSON Machine. Let's say you ended up somewhere in the middle of a huge file and your items have some kind of ID. I'd suggest finding the ID in the file in some huge-file-friendly editor, noting the byte position of the next item to be iterated (for example 987654321), and then doing something along the lines of:
Keep in mind that the JSON pointer you used when you started iteration before the failure from the beginning will most likely not work as the position you specified might be inside some structure already.
I couldn't figure out how to start iterating items from specific position. If I have a huge json file and at some point something goes wrong, how to continue process from some position without need to iterate from the beginning for many hours again? Many thanks!
The text was updated successfully, but these errors were encountered: