The postgresql adapter will fail to see tables in any schema except the first one listed due to the way it parses the schema search path.
For instance, using a connection such as:
development:
adapter: postgresql
database: ...
username: ...
password:
schema_search_path: public,partitions
Will only show tables in the public schema. This occurs because the schema list includes spaces when queried ie: "public, partitions" and when converted into a query it will look like: "'public',' partitions'" and hence 'partitions' will be missed.
The patch is pretty trivial:
175c175
< schemas = schema_search_path.split(/,/).map { |p| quote(p) }.join(',')
---
> schemas = schema_search_path.split(/\s*,\s*/).map { |p| quote(p) }.join(',')
Hope that helps,
.adam sanderson
Oh this is showing up in postgresql 8.1, I don't know if this behavior existed prior to 8.1.