Feature #13331

Support the default sql_mode from MySQL 8

Added by José Raddaoui Marín 2 months ago. Updated 17 days ago.

Status:NewStart date:05/25/2020
Priority:MediumDue date:
Assignee:-% Done:

0%

Category:Data model / ORM
Target version:-
Google Code Legacy ID: Tested version:2.6
Sponsored:No Requires documentation:

Description

As a follow-up to #13313, it would be great if AtoM could work with the default sql_mode in MySQL 8:

ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION

Known issues:

  • We don't support STRICT_TRANS_TABLES: some work has been done to allow it (see related issue) but we're not there yet. Ideally, we would improve validation and error reporting to be able to inform the user about truncated or invalid data.
  • We allow zeros in dates in the event dates and I'm not sure if we allow entire zero dates. Either way, this two modes will join STRICT_TRANS_TABLES in a future MySQL version, so they should be addressed altogether.
  • Unknown issue: supporting ONLY_FULL_GROUP_BY may require changes too.

Related issues

Related to Access to Memory (AtoM) - Task #13313: Reconsider the inclusion of STRICT_TRANS_TABLES in the sq... In progress 05/11/2020
Related to Access to Memory (AtoM) - Bug #13214: Importing a CSV with '--skip-nested-set-build' raises an ... Verified 11/19/2019

History

#1 Updated by José Raddaoui Marín 2 months ago

  • Related to Task #13313: Reconsider the inclusion of STRICT_TRANS_TABLES in the sql_mode added

#2 Updated by José Raddaoui Marín about 1 month ago

Running a CSV import with the skip-nested-set-build option enabled was not working if STRICT_TRANS_TABLES was enabled in the sql_mode. This has been addressed in:

https://github.com/artefactual/atom/pull/1127

A bit closer to support the default sql_mode from MySQL 8.

#3 Updated by José Raddaoui Marín 27 days ago

  • Related to Bug #13214: Importing a CSV with '--skip-nested-set-build' raises an error in 2.5.x added

#4 Updated by José Raddaoui Marín 17 days ago

The following commit removed STRICT_TRANS_TABLES from the sql_mode in the 2.7.0.0 Vagrant box:

https://github.com/artefactual-labs/am-packbuild/pull/271

We may want to restore it to be able to find the remaining issues in the development/test environments.

Also available in: Atom PDF