{"issue":{"created_at":"2011-11-18T10:26:55Z","state":"closed","updated_at":"2011-11-21T15:17:41Z","comments":5,"user":{"gravatar_id":"4884a61106c64a7437fc3e9eb5819b7c","id":122018,"url":"https://api.github.com/users/razum2um","login":"razum2um","avatar_url":"https://secure.gravatar.com/avatar/4884a61106c64a7437fc3e9eb5819b7c?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png"},"body":"in my controller i have:\r\n\r\nCarMark.find(params[:car_mark_id]).car_models\r\n\r\nwhich generates proper SQL in RAILS_ENV=production rails c:\r\nEXEC sp_executesql N'SELECT TOP (1) [car_marks].* FROM [car_marks] WHERE [car_marks].[id] = @0', N'@0 int', @0 = 1  [[\"id\", 1]]\r\n\r\nbut running on production under nginx+passenger it gives\r\nEXEC sp_executesql N'SELECT TOP (1) [car_marks].* FROM [car_marks] WHERE [car_marks].[id] = @0', N'@0 int', @0 = 1)\r\n\r\nFull error log entry:\r\nActiveRecord::StatementInvalid (ArgumentError: argument out of range: EXEC sp_executesql N'SELECT TOP (1) [car_marks].* FROM [car_marks] WHERE [car_marks].[id] = @0', N'@0 int', @0 = 1):\r\n  app/controllers/car_models_controller.rb:5:in `index'","assignee":null,"id":2278786,"pull_request":{"patch_url":null,"html_url":null,"diff_url":null},"number":63,"labels":[],"title":"Occasionally run accross ArgumentError: argument out of range","closed_at":"2011-11-21T15:17:41Z","html_url":"https://github.com/rails-sqlserver/tiny_tds/issues/63","url":"https://api.github.com/repos/rails-sqlserver/tiny_tds/issues/63","milestone":null},"action":"created","comment":{"created_at":"2011-11-21T15:17:41Z","updated_at":"2011-11-21T15:17:41Z","user":{"gravatar_id":"4884a61106c64a7437fc3e9eb5819b7c","id":122018,"url":"https://api.github.com/users/razum2um","login":"razum2um","avatar_url":"https://secure.gravatar.com/avatar/4884a61106c64a7437fc3e9eb5819b7c?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png"},"body":"partially \"solved\" by switching to nginx-proxy+unicorn.\r\nthe problem has gone, but this remains to be strange to me.\r\n\r\njust leave this ticket close, maybe someone will confirm this later","id":2816277,"url":"https://api.github.com/repos/rails-sqlserver/tiny_tds/issues/comments/2816277"}}