phalcon-devtools icon indicating copy to clipboard operation
phalcon-devtools copied to clipboard

Postgresql schema not set when creating new Db Adapter

Open CheckMater opened this issue 12 years ago • 1 comments

No matter which schema you set when creating the DbAdapter it always uses the public schema.

The only fix for this is manually setting the schema in the initialize method in the model object in this way:

public function initialize() { $this->getModelsManager()->setModelSchema($this, 'the_schema_name'); }

Which I think is unnecesary since the schema must be set in the adapter creation.

I posted this in the Phalcon forum: http://forum.phalconphp.com/discussion/2251/database-adapter-not-setting-schemas-in-postgresql

Greetings!

CheckMater avatar Oct 24 '14 03:10 CheckMater

Sorry, I created this in the wrong project

CheckMater avatar Oct 24 '14 03:10 CheckMater