14.01.2013 Views

IBM Informix Developer's Handbook - IBM Redbooks

IBM Informix Developer's Handbook - IBM Redbooks

IBM Informix Developer's Handbook - IBM Redbooks

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

database: stores7<br />

pool: 5<br />

timeout: 5000<br />

host: kodiak<br />

port: 9089<br />

username: informix<br />

password: password<br />

# Warning: The database defined as 'test' will be erased and<br />

# re-generated from your development database when you run 'rake'.<br />

# Do not set this db to the same as development or production.<br />

test:<br />

adapter: mysql<br />

database: stores7<br />

username: root<br />

password:<br />

host: localhost<br />

C:\work\stores7\config><br />

The adapter parameter is set to the reference name of the Data Server Ruby<br />

driver ibm_db. It also contains the host name and the port parameter with the<br />

details about the DRDA <strong>Informix</strong> instance. These details are the same as used in<br />

the Data Server driver for ODBC/CLI.<br />

For a list of all the parameters, refer to:<br />

http://publib.boulder.ibm.com/infocenter/db2luw/v9r7/topic/com.ibm.swg.im.dbcli<br />

ent.ruby.doc/doc/t0052780.html<br />

11.3 Database operations<br />

This section provides examples of using both Ruby drivers to perform basic<br />

operations against an <strong>IBM</strong> <strong>Informix</strong> database server. It also demonstrates how to<br />

use the Rails Adapter to create basic web applications.<br />

Chapter 11. Working with Ruby on Rails 373

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!