Hi, I wonder what the exact parameters for the upload-delete table event are? By accident I coded (generated) an upload-delete event like follows:
That runs without any problem (what makes me glad). The column amount isn't part of the primary key of the table neither in the consolidated nor in the remote database.
But the documentation seems to say only primary key columns are allowed as parameters for this event:
upload_delete table event
Of course I don't need the non-pk parameter but I wonder if the doc is wrong or that behaviour may be changed in future releases?
Mayby someone can clarify because that would have impact on the code generation tool. TIA Chris Werner asked 12 Aug '14, 12:18 Chris Werner |
The table lists the required parameters (all PK columns) and some of the optional named parameters. Other named parameters, including non-PK columns, can also be used. FYI, the {ml o.} syntax is only applicable to the upload_update event. answered 19 Aug '14, 12:36 Graham Hurst Blob column values are not uploaded for delete operations, and so should not be used.
(19 Aug '14, 13:58)
Bill Somers
|
What's the schema for the table that was generated?
Consolidated (Oracle):
Remote (Ultralite):
It is possible that Mobilink wants to compare old and new values before deleting the record. E.g. imagine if someone already modified the field "amount". If you want to delete it, because you have old values, you probably will not want to do this. And in theory, you have to fetch the changes again and delete the record.
E.g. the upload part is described here: http://dcx.sybase.com/index.html#1200/en/mlstart/foursteps-ml-basics.html
Thanks Vlad, you are right, the text explains the behaviour: "The upload consists of a set of new and old row values for rows modified in the remote database. (Updates have new and old row values; deletes have old values; and inserts have new values.)" and that makes sense too. Then the documentation for the upload-delete table event explains the parameters wrong: http://dcx.sybase.com/index.html#sa160/en/mlserver/upload-delete-ml-scriptsref.html*d5e19662
I will not be surprised if these parameters go through all synchronization scripts. Because the request from the device has already reached the server, and it is up to MobiLink to filter or not, parameters that came from the client :)