Updating record from zoho crm to zoho reports

Updating record from zoho crm to zoho reports

I have created a custom function in zoho crm which fetch data from Potentials and insert into zoho reports.  I created a rule on basis of create or edit. When I update a record it always insert a new record in zoho reports. I want to update that record not want to insert a new row. 
resp = zoho.crm.getRecordById("Potentials",input.id);
info resp;
stage=resp.get("Stage");
name=resp.get("Potential Name");
date=resp.get("Closing Date");
id=(resp.get("POTENTIALID")).toLong();
info stage;
info name;
creatingMap=map();
creatingMap.put("POTENTIALID",input.id);
creatingMap.put("Stage",stage);
creatingMap.put("Potential Name",name);
creatingMap.put("Closing Date",date);
result = zoho.reports.createRow("Zoho CRM Reports","uploadpotentials",creatingMap);
info result;