Bulk processing of objectsΒΆ
MFSQL Connector up to version 4 is structured to perform updates to and from SQL using a series of different operations, often performing the same operation multiple times.
- There are two main routines:
. get objver . get / update / delete / undelete / destroy objid
rollback is not supported check in checkout is performed on a single object and bulk update is a series of individual checkin/out operations
sync errors are only detected at a late stage in the processing
when checked out, it does not re-attempt the update.
it is not possible to update only changed objects.
error checking is limited
The main method of data exchange is XML.
There are a number of procedures doing more or less the same thing spmfupdatetable spmfupdatemfilestomfsql spmfupdatetableinbatches spmftableaudit spmfupdateobjectchangehistory spmfdeleteobject spmfundeleteobject spmfdeleteobjectlist spmfdeleteadhocproperty spmfdeleteobjectversionlist spmfgetobjectvers spmfobjecttypeupdateclassindex spmfremoveadditionalproperties spmfupdateallincludedinapptables spmfupdateitembyitem spmfupdatetablewithlastmodifieddate
There are three main SQL tables a) Class Table b) Change History c) Audit History There are two updatemethods 1 from MF to SQL 0 from SQL to MF The operation can be performed for a single class, multi classes, or all classes The operation can include create / edit / delete / undelete The class table either retain deleted object details or not. The operation is done on all objects, a list of object, or from a specific date. (the filter to process only records by user is a subset of a list of objects
Each operation should a) check that the history is up to date b) check that the objver is up to date c) check that the objid is up to date Only changed objects should be updated (https://www.mssqltips.com/sqlservertip/6497/how-to-identify-which-sql-server-columns-changed-in-a-update/) Use JSON for data exchange