Titanium JIRA Archive
Alloy (ALOY)

[ALOY-1136] SQL sync adapter: add method or optimize query for bulk-updates

GitHub Issuen/a
TypeImprovement
PriorityMedium
StatusOpen
ResolutionUnresolved
Affected Version/sn/a
Fix Version/sn/a
ComponentsModels
Labelsn/a
ReporterTim Poulsen
AssigneeUnknown
Created2014-09-12T15:38:03.000+0000
Updated2018-03-07T22:25:37.000+0000

Description

The SQL sync adapter's create/update method is currently best-suited to updating a single model at a time. The query could be optimized, or a separate method could be added to make bulk updates (multiple models in a single operation) so that such changes could be done in a more performant method. Options might include - update REPLACE INTO query to pass multiple VALUES - execute multiple queries, but wrap in transaction so that there's a single atomic operation on the DB A transaction should be used in either case to provide recovery in the case of an error during the update.

Comments

No comments

JSON Source