REST API update2 creates duplicate comment records

Posted by Rollbase User on 27-Dec-2011 15:42

I use REST api update2 to update the comment field on a rollbase record with a message "This is a test comment". This will create a new Comment record (as expected). $sessionID = loginRollbase(); $url = 'http://www.rollbase.com/rest/api/update2?sessionId=' . $sessionID; $params = '&useIds=false' . '&id=45881868' . '&comment=This is a test comment'; REST("POST",$url,"update2",$params); logoutRollbase($sessionID);  However, any time another field on same record is updated after a comment has been created, a new duplicate comment gets created. Here I will update the refund notes field and when the script is executed, the refund notes field will be updated AND the previous comment will get duplicated. $sess

All Replies

Posted by Admin on 27-Dec-2011 15:55

This is a feature, not a bug: every time "Comments" field has value it creates a new record. Do not supply any value to this field.

Posted by Admin on 27-Dec-2011 16:16

I don't supply a value to the comments field when I run the code a second time. The first time I run the code, it is: '&comment=This is a test comment';. Then I change the code to: '&refund_notes=This is refund notes'; and it creates a duplicate comment entry even though I only include the refund_notes field.

Posted by Admin on 27-Dec-2011 18:58

I should check this.

This thread is closed