Command to get data as javascript variables


Hi! Dear,

Would you please let me know is there anyway to have result record as (text)variables in Javascript ?

Image as:


function getData(){

base(‘New Playlists’).select({
filterByFormula: ‘ID = MyFunIDValue’,
}).eachPage(function page(records, fetchNextPage) {
records.forEach(function(record) {
return record.get(‘ID’);

}, function done(error) {



var data = getData();



in this way I could have only result “undefined”…

I thought it is trouble with asymetric treatment.

but it didn’t work well

like this…


Please tell me what should be fixed or is there another command smart,

like just