Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Ruby > Newbie: populate an array from database (oci8) results

Thread Tools

Newbie: populate an array from database (oci8) results
Posts: n/a
Simple, newbie query. Should be easy enough, but my Ruby knowledge is
in it's early stages.

I want to populate a 2d array with results of an Oracle DB query.

I'm doing something like:

connection ='yada', 'yada', 'yada')
connection.exec('select one, two from table_name') do |r|

And now I'm lost. What to actually do with r ?

Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Database Database Database Database Computer Information 0 09-27-2012 02:43 AM
DataBase DataBase DataBase DataBase Computer Information 0 09-26-2012 09:40 AM
UPDATE : Help Required to Populate search results - Array Search Craig Keightley Javascript 10 06-29-2005 10:54 AM
help required to populate search results Craig Keightley Javascript 1 06-24-2005 08:15 AM
Populate a popup window with clickable records from an Access DB and upon clicking, populate a selectbox on the original webpage with the clicked record Enjoy Life ASP General 2 02-23-2005 10:48 PM