Skip to content

Error rails 7.2.2 plsql 17.6 restrict - unrestrict, structure.sql #326

@ElWorking

Description

@ElWorking

When there is an error in the structure.sql dump due to rule restrictions generated by the PL/pgSQL version, Apartment does not have a native solution for it. This workaround is added in the project initializer.

require 'apartment/adapters/postgresql_adapter'

Apartment::Adapters::PostgresqlSchemaFromSqlAdapter::PSQL_DUMP_BLACKLISTED_STATEMENTS =
  (Apartment::Adapters::PostgresqlSchemaFromSqlAdapter::PSQL_DUMP_BLACKLISTED_STATEMENTS + [/\\restrict/i, /\\unrestrict/i]).freeze

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions