Prev | Current Page 60 | Next

Kevin Marshall, Chad Pytel, and Jon Yurek

"Pro Active Record: Databases with Ruby and Rails"

The value can
be either db2 or ibm-db2 for the IBM adapter.
database: The name of the database that you are attempting to connect to.
username: Optional parameter containing the username of the user as whom you wish to
connect to the database. The default value is nothing.
password: Optional parameter containing the password of the user as whom you wish to
connect to the database. This value is provided in plain text. The default value is nothing.
schema: Optional parameter containing the initial database schema to be set.
The following example shows how to open an Active Record database connection for DB2:
ActiveRecord::Base.establish_connection(:adapter => "db2",
:database => "artest", :username => "kevin", :password => "test")
Firebird Parameters
The minimum Firebird requirements are the adapter and database parameters. Here is the
complete list of parameters to consider:
adapter: Specifies that this is connection information for a Firebird database. The value
should be firebird.
database: The name of the database that you are attempting to connect to.


Pages:
48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72