[ruby-oci8-devel] rowid?

Amos a.goo0h at gmail.com
Thu Jan 17 10:13:54 EST 2008


On Jan 17, 2008 7:53 AM, KUBO Takehiro <kubo at jiubao.org> wrote:

> Hi,
>
> Here is a mailing list for who develop ruby-oci8 itself, not for who
> use ruby-oci8 to develop other applications.
>


Sorry. A post back in Sep '07 to the general list/group never got a
response, so I wasn't sure where else to post the query.



>
> The following code works on 1.0.
>  cursor = conn.parse('select rowid, t.* from dual t')
>  cursor.define(1, String, 23) # fetch 1st column as a String.
>  cursor.exec
>  while row = cursor.fetch
>    puts row[0]
>  end
>
> As for OCI8::Cursor#rowid, it is available to get rowids of
> inserted rows.
>   cursor = conn.parse('insert into foo values (1, 2)')
>   cursor.exec
>   rowid = cursor.rowid # inserted row's rowid.
>


I'll follow-up my query to the general list/group with this info so others
can benefit.

Thanks.

Amos
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://rubyforge.org/pipermail/ruby-oci8-devel/attachments/20080117/77ba6115/attachment.html 


More information about the ruby-oci8-devel mailing list