Thursday, November 18, 2010

rails 3.0.3 and activerecord-sqlserver-adapter (3.0.5) error on windows

rails 3.0.1
Using activerecord-sqlserver-adapter (3.0.5)
SELECT TOP (1) [users].* FROM [users] WHERE ([users].[id] = 1)

rails 3.0.3
Using activerecord-sqlserver-adapter (3.0.5)
ActiveRecord::StatementInvalid (ODBC::Error: 37000 (102) [Microsoft][ODBC SQL Server Driver][SQL Server]Incorrect syntax near 'LIMIT'.:
SELECT [users].* FROM [users] WHERE ([users].[id] = N'1') LIMIT 1)
:

I just found this and I don't have a fix other than rolling back to 3.0.1

1 comment:

Alexander Zolotko said...

There is a bug on this issue in activerecord-sqlserver-adapter bugtracker:

https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/issues/closed/#issue/69