This project is archived and is in readonly mode.

#2695 ✓committed
Jeff Dean

[patch] fix db:structure:dump for multiple schemas in postgres

Reported by Jeff Dean | May 22nd, 2009 @ 05:51 AM | in 2.x

This patch fixes a bug in db:structure:dump for postgres when there are multiple schema_search_paths.

development:
  adapter: postgresql
  username: user
  schema_search_path: foo, bar
  password:

Currently in rails, if you have a database.yml with multiple values in schema_search_path, db:structure:dump blows up. This patch properly formats the above database.yml command like so:

@@@pg_dump -i -U "user" -s -x -O -f development_structure.sql --schema=bar --schema=foo my_database@@@

Postgres allows for multiple schemas to be passed to pgdump - for more information see:

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

People watching this ticket

Attachments

Referenced by

Pages