# ODBC Oracle error for indexes() call "Invalid string or buff

**URL:** <https://www.ruby-forum.com/t/odbc-oracle-error-for-indexes-call-invalid-string-or-buff/81988>\
**Category:** Ruby\
**Created:** [January 16, 2007, 7:00pm UTC](https://www.ruby-forum.com/t/odbc-oracle-error-for-indexes-call-invalid-string-or-buff/81988 "2007-01-16T19:00:59Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Chris\_McMahon](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/74df32/32.png) [@Chris\_McMahon](https://www.ruby-forum.com/u/Chris_McMahon)\
**Post date:** [January 16, 2007, 7:00pm UTC](https://www.ruby-forum.com/t/odbc-oracle-error-for-indexes-call-invalid-string-or-buff/81988/1 "2007-01-16T19:00:59Z")

</div>

I have a Ruby program talking to MS ODBC Driver for Oracle on WinXP.  
The script makes successful calls to columns() function, but for a call  
to indexes(), returns

ora\_index\_p4.rb:185:in `indexes’: S1090 (0) [Microsoft][ODBC driver for  
Oracle]Invalid string or buffer length (ODBC::Error)

The code is something like:  
#######################################  
require ‘odbc’  
get\_new = @conn.run(“select table\_name from dba\_tables where owner =  
‘#{new\_db\_name}’”)  
tables = get\_new.fetch\_all

tables.each do |table|  
columns = @conn.columns(table.to\_s)  
indexes = @conn.indexes(table.to\_s")  
end  
##########################################

The strange part is that this call was working on this host last week,  
so it’s as if something has changed on the host. I did in fact remove  
and re-install Ruby 185-21 Windows one-click installer, but the  
behavior remains the same.

Any suggestions would be welcome.
