I started learning redis and nodejs , I am getting data from third party api call. I want to save this data into my redis server. I am able to do that but I got a problem that if i get data in json array with multiple keys I am not able to insert it. How can I solve this issue?
My data is:
keys
[123,3435,455,455]
value
[{name:'shakti'},{name:'amit'},{name:'amiit'},{name:'sad'}]
I want to save this data at once in to key value form without using any for loop. Currently I am using for loop like
for(var i=0i<keys.length;;i++){
redisClient.set(keys[i],data);
}
Please help me to solve this. Thanks