Drupal database update failing because metatag sql syntax error

Created on 8 January 2024, 11 months ago

Problem/Motivation

I am upgrading my drupal from 9 to 10. when i am running drush updb command it fails with following sql syntax error

  [error]  SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'AS ""
> FROM
> "" ""
> WHERE LIKE 'a:%' ESCAPE '\\'
> LIMIT 100 OFFSET 0' at line 1: SELECT "entity_id" AS "entity_id", "revision_id" AS "revision_id", "langcode" AS "langcode",  AS ""
> FROM
> "" ""
> WHERE LIKE :db_condition_placeholder_0 ESCAPE '\\'
> LIMIT 100 OFFSET 0; Array
> (
>     [:db_condition_placeholder_0] => a:%
> )
>
>  [error]  Update failed: metatag_post_update_v2_01_change_fields_to_json
 [error]  Update aborted by: metatag_post_update_v2_01_change_fields_to_json
 [error]  Finished performing updates.

Proposed resolution

I have created patch to fix this issue. I have not tested it kindly test and do required changes.

🐛 Bug report
Status

Needs review

Version

2.0

Component

Code

Created by

🇮🇳India lvishal

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024