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

Sakila/PostgreSQL: Don't fail if language plpgsql already exists #9700

Merged
merged 1 commit into from Jan 8, 2020

Conversation

rweisleder
Copy link
Contributor

When using the Sakila DB with the Docker image postgres:12.1 the initialisation fails with:
ERROR: language "plpgsql" already exists

With PostgreSQL 8.4 (see [1]) and earlier it was only possible to execute:
CREATE [ PROCEDURAL ] LANGUAGE name

Starting with PostgreSQL 9.0 (see [2]) it is possible to execute:
CREATE [ OR REPLACE ] [ PROCEDURAL ] LANGUAGE name

This commit makes the SQL script incompatible with PostgreSQL 8.4 and earlier.

[1] https://www.postgresql.org/docs/8.4/sql-createlanguage.html
[2] https://www.postgresql.org/docs/9.0/sql-createlanguage.html

When using the Sakila DB with the Docker image postgres:12.1 the
initialisation fails with:
  ERROR:  language "plpgsql" already exists

With PostgreSQL 8.4 (see [1]) and earlier it was only possible to
execute:
  CREATE [ PROCEDURAL ] LANGUAGE name

Starting with PostgreSQL 9.0 (see [2]) it is possible to execute:
  CREATE [ OR REPLACE ] [ PROCEDURAL ] LANGUAGE name

This commit makes the SQL script incompatible with PostgreSQL 8.4
and earlier.

[1] https://www.postgresql.org/docs/8.4/sql-createlanguage.html
[2] https://www.postgresql.org/docs/9.0/sql-createlanguage.html
@knutwannheden knutwannheden merged commit 8c225c4 into jOOQ:master Jan 8, 2020
@knutwannheden
Copy link
Contributor

@rweisleder Thank you very much for your contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

None yet

2 participants