Hi all,
I am trying to get the mirror page urls for a large number of records and update the same in a table for reporting purpose. I have tried nms.delivery.GetMirrorURL() and successfully got the urls in a table. But the problem is it takes a lot of time to get the work done (approx. 90 mins. for around 8000 records). Can anyone suggest a more time efficient way to get these urls into the table (using a workflow). Below is the code i tried.
Code:
var sql1=" SELECT ibId,idId FROM "+vars.tableName;
var sql2= sqlSelect("collection,bId:int,dId:int",sql1);
var mirror;
for each (var sql2 in sql2.collection){
mirror = nms.delivery.GetMirrorURL(sql2.dId.toString(), sql2.bId.toString())
sql = "UPDATE "+ vars.tableName +" SET sMirror='"+mirror+"' WHERE ibId="+sql2.bId.toString();
logInfo(sqlExec(sql));
sqlExec(sql);
}
This code is written in a javascript activity in a workflow.
Regards,
Jayesh Bhanushali