I’ve a remote database create using Oracle. This database use schemas.
I tried to connect to it using Ruby On Rails,with this file Database.yml
:
development:
adapter: oci
host: liber
database: ENERGIA
username: user
password: pass
test:
adapter: oci
host: liber
database: ENERGIA
username: user
password: pass
production:
adapter: oci
host: liber
database: ENERGIA
username: user
password: pass
Where “ENERGIA” is a schema’s name.
I want to create a model for a table named “Platts” that is into
ENERGIA.
I use this command: ruby script/generate scaffold platt action_name
But everytime Rails Tell me that this Table doesn’t exist!
Can someone tell me what’s the problem?
Where “ENERGIA” is a schema’s name.
I want to create a model for a table named “Platts” that is into
ENERGIA.
The oracle adapter doesn’t use the database parameter.
You can connect passing a tnsnames.ora defined name in the host
parameter. e.g. If you have oracle client installed and this: