A
A
ArtemEfremov2020-04-30 12:53:58
JavaScript
ArtemEfremov, 2020-04-30 12:53:58

Operations with a certain number of elements in a loop, how?

Essence of the question:

- you need to call the users.get method
In this method, in the user_ids parameter, the maximum number of elements separated by commas: 1000

- there are 5000 elements in the database (this is not a constant value, the number will always be more)

- how to make sure that if the number is greater than 1000, then call the method again. (And so on until it goes through all the elements in the database)

If it's not difficult, you can give small examples, thanks.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
E
edward_freedom, 2020-04-30
@edward_freedom

With the execute method , 25 methods can be called with a single request. An example is provided on the documentation page

M
mahmudchon, 2020-04-30
@mahmudchon

There's also an offset for that. So that the selection does not start from the beginning.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question