{"issue":{"state":"open","pull_request":{"diff_url":null,"html_url":null,"patch_url":null},"user":{"avatar_url":"https://secure.gravatar.com/avatar/c2dc9c02ce7a041285725a4fc9e5f6d2?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"c2dc9c02ce7a041285725a4fc9e5f6d2","url":"https://api.github.com/users/sobrinho","login":"sobrinho","id":26460},"milestone":null,"assignee":null,"labels":[],"updated_at":"2011-11-03T19:49:18Z","closed_at":null,"comments":8,"url":"https://api.github.com/repos/rails/rails/issues/3483","body":"Hello,\r\n\r\nirb:\r\n\r\n``` ruby\r\nputs User.where(:id => [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 20, 30]).to_sql\r\n#=> SELECT \"users\".* FROM \"users\"  WHERE \"users\".\"id\" IN (1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 20, 30)\r\nputs User.where(:id => 1..10).to_sql\r\n#=> SELECT \"users\".* FROM \"users\"  WHERE \"users\".\"id\" BETWEEN 1 AND 10\r\nputs User.where(:id => [1..10, 20, 30]).to_sql\r\n#=> TypeError: Cannot visit Range\r\n```\r\n\r\nI'm expecting this:\r\n\r\n``` ruby\r\nputs User.where(:id => [1..10, 20, 30]).to_sql\r\n#=> SELECT \"users\".* FROM \"users\"  WHERE \"users\".\"id\"  BETWEEN 1 AND 10 OR \"users\".\"id\" IN(20, 30)\r\n```\r\n\r\nSeems reasonable?","html_url":"https://github.com/rails/rails/issues/3483","number":3483,"title":"Query using an array of integers and ranges","id":2100091,"created_at":"2011-10-31T17:57:13Z"},"action":"created","comment":{"user":{"avatar_url":"https://secure.gravatar.com/avatar/f29327647a9cff5c69618bae420792ea?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"f29327647a9cff5c69618bae420792ea","url":"https://api.github.com/users/tenderlove","login":"tenderlove","id":3124},"updated_at":"2011-11-03T19:49:18Z","url":"https://api.github.com/repos/rails/rails/issues/comments/2622116","body":"ok! I won't be able to fix this for a couple weeks, but I will do it.  Thanks for the failing test case!","id":2622116,"created_at":"2011-11-03T19:49:18Z"}}