Connecting to sqlserver from RHEL4 issue

I’ve downloaded and compiled from source the following libraries:
unixODBC 2.2.11
FreeTDS 0.64 (configured with unixodbc, tdsver 8.0 and msdblib)
ruby-odbc 0.996
ruby-dbi-all 0.0.23

I can confirm connecting using my DSN with tsql and isql. The DSN
specifies "emulate little endian.

Once I start my Rails 1.1.6 (ruby 1.8.5) application, however,
ActiveRecord objects that have integer (defined on sqlserver as int(4))
fields don’t get filled in, rather, they have values like
‘180388626433’, instead of a value like ‘5’.

Application works fine when run from Win32 using WEBrick, mongrel or
Apache. This is occuring on RHEL4.

Thanks.

I should add that reloading the page will get some of the foreign keys
on the models updated. Multiple refreshes leaves different integer
fields filled in, for example, sometimes “customer_id” is valid,
sometimes it is not.

I downloaded and built ruby-odbc 0.9991, configured with the
–with-dlopen flag. Now everything seems to work. Can’t explain it…
maybe the long weekend helped.

The server platform is RHEL4 (x86_64).

tgl