I have in my js class two methods, addOrder(order) and editOrder(order), the addOrder contains a relations using setRelation… and in the editOrder I want to edit the column who has a relation with another table.
I had used this:
var whereClause = “objectId=’” + order.id + “’”;
var queryBuilder = Backendless.DataQueryBuilder.create().setWhereClause(whereClause);
var orderContent = order.content;
var savedOrder= Backendless.Data.of( “order” ).find( queryBuilder );
var orderData= Backendless.Data.of( “order” )
var contentChanged = orderData.setRelation(savedOrder,“content”,[orderContent]);
And then I had invoke a json using editOrder contains “content”:null,
in the build response, the content is null but in the table not changed.
How to change it in the table?