View Issue Details

IDProjectCategoryView StatusLast Update
0003780Composrcore_database_driverspublic2019-02-22 14:58
ReporterChris GrahamAssigned To 
PrioritynormalSeverityfeatureReproducibilityN/A
Status non-assignedResolutionopen 
Product Version 
Target VersionFixed in Version 
Summary0003780: Make use of MySQL REPLACE INTO syntax
Descriptionput_into_cache and set_value are both highly trafficed functions that do a query_delete (DELETE FROM) followed by a query_insert (INSERT INTO). These cases could be single REPLACE INTO calls in MySQL.

The ideal solution would be to extend the insert_into method to change $fail_ok to take constants QUERY_FAIL_HARD, QUERY_FAIL_SILENT, and QUERY_REPLACE_INTO.
Then each database driver could do it's own implementation. Almost every database backend has some kind of syntax for it https://en.wikipedia.org/wiki/Merge_(SQL)

However, a quick and dirty detection of whether MySQL is running, and coding in an alternative query, would be fine.
TagsType: Performance
Attach Tags
Time estimation (hours)1
Sponsorship open

Activities

There are no notes attached to this issue.

Issue History

Date Modified Username Field Change
2019-02-22 14:58 Chris Graham New Issue
2019-02-22 14:58 Chris Graham Tag Attached: Type: Performance