{"action":"created","issue":{"url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3291","labels_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3291/labels{/name}","comments_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3291/comments","events_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3291/events","html_url":"https://github.com/cockroachdb/cockroach/pull/3291","id":120026668,"number":3291,"title":"sql: add failing test for aliased subquery","user":{"login":"tamird","id":1535036,"avatar_url":"https://avatars.githubusercontent.com/u/1535036?v=3","gravatar_id":"","url":"https://api.github.com/users/tamird","html_url":"https://github.com/tamird","followers_url":"https://api.github.com/users/tamird/followers","following_url":"https://api.github.com/users/tamird/following{/other_user}","gists_url":"https://api.github.com/users/tamird/gists{/gist_id}","starred_url":"https://api.github.com/users/tamird/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tamird/subscriptions","organizations_url":"https://api.github.com/users/tamird/orgs","repos_url":"https://api.github.com/users/tamird/repos","events_url":"https://api.github.com/users/tamird/events{/privacy}","received_events_url":"https://api.github.com/users/tamird/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/cockroachdb/cockroach/labels/bug","name":"bug","color":"fc2929"},{"url":"https://api.github.com/repos/cockroachdb/cockroach/labels/SQL","name":"SQL","color":"bfd4f2"}],"state":"open","locked":false,"assignee":{"login":"mjibson","id":41181,"avatar_url":"https://avatars.githubusercontent.com/u/41181?v=3","gravatar_id":"","url":"https://api.github.com/users/mjibson","html_url":"https://github.com/mjibson","followers_url":"https://api.github.com/users/mjibson/followers","following_url":"https://api.github.com/users/mjibson/following{/other_user}","gists_url":"https://api.github.com/users/mjibson/gists{/gist_id}","starred_url":"https://api.github.com/users/mjibson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mjibson/subscriptions","organizations_url":"https://api.github.com/users/mjibson/orgs","repos_url":"https://api.github.com/users/mjibson/repos","events_url":"https://api.github.com/users/mjibson/events{/privacy}","received_events_url":"https://api.github.com/users/mjibson/received_events","type":"User","site_admin":false},"milestone":null,"comments":3,"created_at":"2015-12-02T20:15:16Z","updated_at":"2015-12-07T20:34:36Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/cockroachdb/cockroach/pulls/3291","html_url":"https://github.com/cockroachdb/cockroach/pull/3291","diff_url":"https://github.com/cockroachdb/cockroach/pull/3291.diff","patch_url":"https://github.com/cockroachdb/cockroach/pull/3291.patch"},"body":"Reduced version of #3288. Fails with:\r\n```\r\n--- FAIL: TestLogic (0.06s)\r\n\tlogic_test.go:426: testdata/subquery:139: expected success, but found pq: qualified name \"x.k\" not found\r\n```\r\nNote this branch is on the main repo, not my fork (so you can push commits to it).\n\n<!-- Reviewable:start -->\n[<img src=\"https://reviewable.io/review_button.png\" height=40 alt=\"Review on Reviewable\"/>](https://reviewable.io/reviews/cockroachdb/cockroach/3291)\n<!-- Reviewable:end -->\n"},"comment":{"url":"https://api.github.com/repos/cockroachdb/cockroach/issues/comments/162653047","html_url":"https://github.com/cockroachdb/cockroach/pull/3291#issuecomment-162653047","issue_url":"https://api.github.com/repos/cockroachdb/cockroach/issues/3291","id":162653047,"user":{"login":"mjibson","id":41181,"avatar_url":"https://avatars.githubusercontent.com/u/41181?v=3","gravatar_id":"","url":"https://api.github.com/users/mjibson","html_url":"https://github.com/mjibson","followers_url":"https://api.github.com/users/mjibson/followers","following_url":"https://api.github.com/users/mjibson/following{/other_user}","gists_url":"https://api.github.com/users/mjibson/gists{/gist_id}","starred_url":"https://api.github.com/users/mjibson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mjibson/subscriptions","organizations_url":"https://api.github.com/users/mjibson/orgs","repos_url":"https://api.github.com/users/mjibson/repos","events_url":"https://api.github.com/users/mjibson/events{/privacy}","received_events_url":"https://api.github.com/users/mjibson/received_events","type":"User","site_admin":false},"created_at":"2015-12-07T20:34:36Z","updated_at":"2015-12-07T20:34:36Z","body":"There is also:\r\n\r\n```\r\n> select * from x where exists(select a from no_such_table);\r\n+---+\r\n| a |\r\n+---+\r\n+---+\r\n```\r\n\r\nWhere it successfully returns a result when a bogus table is specified."}}