{"action":"created","issue":{"url":"https://api.github.com/repos/rails/rails/issues/20077","repository_url":"https://api.github.com/repos/rails/rails","labels_url":"https://api.github.com/repos/rails/rails/issues/20077/labels{/name}","comments_url":"https://api.github.com/repos/rails/rails/issues/20077/comments","events_url":"https://api.github.com/repos/rails/rails/issues/20077/events","html_url":"https://github.com/rails/rails/issues/20077","id":74444781,"node_id":"MDU6SXNzdWU3NDQ0NDc4MQ==","number":20077,"title":"PG::ProtocolViolation: ERROR:  bind message supplies 0 parameters, but prepared statement \"\" requires 1","user":{"login":"cxz","id":893973,"node_id":"MDQ6VXNlcjg5Mzk3Mw==","avatar_url":"https://avatars0.githubusercontent.com/u/893973?v=4","gravatar_id":"","url":"https://api.github.com/users/cxz","html_url":"https://github.com/cxz","followers_url":"https://api.github.com/users/cxz/followers","following_url":"https://api.github.com/users/cxz/following{/other_user}","gists_url":"https://api.github.com/users/cxz/gists{/gist_id}","starred_url":"https://api.github.com/users/cxz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cxz/subscriptions","organizations_url":"https://api.github.com/users/cxz/orgs","repos_url":"https://api.github.com/users/cxz/repos","events_url":"https://api.github.com/users/cxz/events{/privacy}","received_events_url":"https://api.github.com/users/cxz/received_events","type":"User","site_admin":false},"labels":[{"id":107191,"node_id":"MDU6TGFiZWwxMDcxOTE=","url":"https://api.github.com/repos/rails/rails/labels/activerecord","name":"activerecord","color":"0b02e1","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/rails/rails/milestones/40","html_url":"https://github.com/rails/rails/milestone/40","labels_url":"https://api.github.com/repos/rails/rails/milestones/40/labels","id":988887,"node_id":"MDk6TWlsZXN0b25lOTg4ODg3","number":40,"title":"4.2.3","description":"","creator":{"login":"rafaelfranca","id":47848,"node_id":"MDQ6VXNlcjQ3ODQ4","avatar_url":"https://avatars3.githubusercontent.com/u/47848?v=4","gravatar_id":"","url":"https://api.github.com/users/rafaelfranca","html_url":"https://github.com/rafaelfranca","followers_url":"https://api.github.com/users/rafaelfranca/followers","following_url":"https://api.github.com/users/rafaelfranca/following{/other_user}","gists_url":"https://api.github.com/users/rafaelfranca/gists{/gist_id}","starred_url":"https://api.github.com/users/rafaelfranca/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rafaelfranca/subscriptions","organizations_url":"https://api.github.com/users/rafaelfranca/orgs","repos_url":"https://api.github.com/users/rafaelfranca/repos","events_url":"https://api.github.com/users/rafaelfranca/events{/privacy}","received_events_url":"https://api.github.com/users/rafaelfranca/received_events","type":"User","site_admin":false},"open_issues":0,"closed_issues":24,"state":"closed","created_at":"2015-02-20T21:21:55Z","updated_at":"2015-06-25T21:29:04Z","due_on":null,"closed_at":"2015-06-25T21:29:04Z"},"comments":21,"created_at":"2015-05-08T18:01:01Z","updated_at":"2018-11-09T18:09:40Z","closed_at":"2015-06-15T20:04:40Z","author_association":"NONE","body":"This issue is related to:\n#12753\n#18469\n#17983\n#17770\n\nTest case:\nhttps://gist.github.com/cxz/64efd78be1167a66f127\n\nActiverecord: 4.2.1\nBug happens only with **postgresql** (works fine with sqlite3).\n\nIn summary:\n\n```\nfrom(arel_table.create_table_alias(where(id: 1).arel, table_name))\n```\n\nfails with:\n\n```\nPG::ProtocolViolation: ERROR:  bind message supplies 0 parameters, but prepared statement \"\" requires 1\n: SELECT \"posts\".* FROM (SELECT \"posts\".* FROM \"posts\" WHERE \"posts\".\"id\" = $1) \"posts\"\n```\n"},"comment":{"url":"https://api.github.com/repos/rails/rails/issues/comments/437445543","html_url":"https://github.com/rails/rails/issues/20077#issuecomment-437445543","issue_url":"https://api.github.com/repos/rails/rails/issues/20077","id":437445543,"node_id":"MDEyOklzc3VlQ29tbWVudDQzNzQ0NTU0Mw==","user":{"login":"LuisDeHaro","id":1963433,"node_id":"MDQ6VXNlcjE5NjM0MzM=","avatar_url":"https://avatars1.githubusercontent.com/u/1963433?v=4","gravatar_id":"","url":"https://api.github.com/users/LuisDeHaro","html_url":"https://github.com/LuisDeHaro","followers_url":"https://api.github.com/users/LuisDeHaro/followers","following_url":"https://api.github.com/users/LuisDeHaro/following{/other_user}","gists_url":"https://api.github.com/users/LuisDeHaro/gists{/gist_id}","starred_url":"https://api.github.com/users/LuisDeHaro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LuisDeHaro/subscriptions","organizations_url":"https://api.github.com/users/LuisDeHaro/orgs","repos_url":"https://api.github.com/users/LuisDeHaro/repos","events_url":"https://api.github.com/users/LuisDeHaro/events{/privacy}","received_events_url":"https://api.github.com/users/LuisDeHaro/received_events","type":"User","site_admin":false},"created_at":"2018-11-09T18:09:40Z","updated_at":"2018-11-09T18:09:40Z","author_association":"NONE","body":"Is there other options besides the brackets trick?\r\n\r\nI just upgraded from Rails 4.2.6 to 5.0.7 and basically half of my queries are now broken.\r\n\r\nThe brackets work but, what's the ultimate solution for this?"}}
{"actor":{"display_login":"LuisDeHaro"}}