Problem/Motivation
When trying to create an article or a basic page in an up-to-date 7.95 site, I get an error, and no new content is created:
PDOException: SQLSTATE[22007]: Invalid datetime format: 1366 Incorrect integer value: 'autocreate' for column `domain-db-name`.`field_data_field_tags`.`field_tags_tid` at row 1: INSERT INTO {field_data_field_tags} (entity_type, entity_id, revision_id, bundle, delta, language, field_tags_tid) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3, :db_insert_placeholder_4, :db_insert_placeholder_5, :db_insert_placeholder_6); Array ( [:db_insert_placeholder_0] => node [:db_insert_placeholder_1] => 98 [:db_insert_placeholder_2] => 99 [:db_insert_placeholder_3] => page [:db_insert_placeholder_4] => 0 [:db_insert_placeholder_5] => und [:db_insert_placeholder_6] => autocreate ) in field_sql_storage_field_storage_write() (line 622 of /data/disk/fast1/static/d771/modules/field/modules/field_sql_storage/field_sql_storage.module).
(this is on an aegir multisite, thus the strange module path, above)
Steps to reproduce
This issue arises only when no field tags are entered when creating content, even though I have not required field tags. The "required" box is unchecked, so the problem is that a null value for the field is not accepted. I checked the database table and null is checked.
This error is not reproduced on all 7.95 sites in the same multisite platform!
Any help resolving this would be appreciated. The server is running mariadb 10.4.25
Proposed resolution
No idea!
Remaining tasks
User interface changes
API changes
Data model changes
Release notes snippet
Issue fork drupal-3349244
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
em-fast1 commentedHi,
I now wonder if this issue is really in the core field module or rather in the date module:
https://www.drupal.org/project/date/issues/998076
Comment #4
em-fast1 commentedThis issue arises only when no field tags are entered when creating content, even though I have not required field tags. The "required" box is unchecked, so the problem is that a null value for the field is not accepted. I checked the database table and null is checked.