Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix message_update_7013 failing on PostgreSQL. #173

Open
wants to merge 1 commit into
base: 7.x-1.x
Choose a base branch
from

Conversation

RoSk0
Copy link

@RoSk0 RoSk0 commented Mar 17, 2017

Latest message update message_update_7013() is failing on PostgreSQL with :

SQLSTATE[42P07]: Duplicate table: 7 ERROR: relation "message_mid_seq" already exists.

because on PostgreSQL serial fields are not NULLs by default. Check Drupal driver for PostgreSQL here includes/database/pgsql/schema.inc:181 DatabaseSchema_pgsql::protected function createFieldSql()

if (isset($spec['type']) && $spec['type'] == 'serial') {
  unset($spec['not null']);
}

and includes/database/pgsql/schema.inc:252 DatabaseSchema_pgsql::protected function processField()

if (isset($field['type']) && $field['type'] == 'serial') {
      unset($field['not null']);
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants