Skip to content
Advertisement

Create a loop to compile multiple records into a new variable

At the moment I am fetching metadata attached to individual record numbers. The process I am using works, but its somewhat cumbersome, especially for larger batches of records:

JavaScript

I am trying to improve this process by creating a loop or sorts to insert each record number to get the same result as above in allData.

JavaScript

However, I am not getting allData in console or any error.

Advertisement

Answer

allData.push() is good

JavaScript
Advertisement