{"action":"created","comment":{"url":"https://api.github.com/repos/apache/flink/pulls/comments/145659580","pull_request_review_id":70489486,"id":145659580,"diff_hunk":"@@ -0,0 +1,51 @@\n+/*\n+ * Licensed to the Apache Software Foundation (ASF) under one\n+ * or more contributor license agreements.  See the NOTICE file\n+ * distributed with this work for additional information\n+ * regarding copyright ownership.  The ASF licenses this file\n+ * to you under the Apache License, Version 2.0 (the\n+ * \"License\"); you may not use this file except in compliance\n+ * with the License.  You may obtain a copy of the License at\n+ *\n+ *     http://www.apache.org/licenses/LICENSE-2.0\n+ *\n+ * Unless required by applicable law or agreed to in writing, software\n+ * distributed under the License is distributed on an \"AS IS\" BASIS,\n+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n+ * See the License for the specific language governing permissions and\n+ * limitations under the License.\n+ */\n+\n+package org.apache.flink.table.api.batch.table.stringexpr\n+\n+import org.apache.flink.table.expressions.{ExpressionParser, Literal, UnresolvedFieldReference}\n+import org.junit.{Assert, Test}\n+\n+class StringExpressionTest {","path":"flink-libraries/flink-table/src/test/scala/org/apache/flink/table/api/batch/table/stringexpr/StringExpressionTest.scala","position":24,"original_position":24,"commit_id":"4cdfd18148a1a4e97e078bee6ccf4ba8c20c8034","original_commit_id":"4cdfd18148a1a4e97e078bee6ccf4ba8c20c8034","user":{"login":"Xpray","id":5170813,"avatar_url":"https://avatars0.githubusercontent.com/u/5170813?v=4","gravatar_id":"","url":"https://api.github.com/users/Xpray","html_url":"https://github.com/Xpray","followers_url":"https://api.github.com/users/Xpray/followers","following_url":"https://api.github.com/users/Xpray/following{/other_user}","gists_url":"https://api.github.com/users/Xpray/gists{/gist_id}","starred_url":"https://api.github.com/users/Xpray/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Xpray/subscriptions","organizations_url":"https://api.github.com/users/Xpray/orgs","repos_url":"https://api.github.com/users/Xpray/repos","events_url":"https://api.github.com/users/Xpray/events{/privacy}","received_events_url":"https://api.github.com/users/Xpray/received_events","type":"User","site_admin":false},"body":"That's great, I should have done this.","created_at":"2017-10-19T10:22:32Z","updated_at":"2017-10-19T10:22:32Z","html_url":"https://github.com/apache/flink/pull/4829#discussion_r145659580","pull_request_url":"https://api.github.com/repos/apache/flink/pulls/4829","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/apache/flink/pulls/comments/145659580"},"html":{"href":"https://github.com/apache/flink/pull/4829#discussion_r145659580"},"pull_request":{"href":"https://api.github.com/repos/apache/flink/pulls/4829"}},"in_reply_to_id":145653182},"pull_request":{"url":"https://api.github.com/repos/apache/flink/pulls/4829","id":146723289,"html_url":"https://github.com/apache/flink/pull/4829","diff_url":"https://github.com/apache/flink/pull/4829.diff","patch_url":"https://github.com/apache/flink/pull/4829.patch","issue_url":"https://api.github.com/repos/apache/flink/issues/4829","number":4829,"state":"open","locked":false,"title":"[FLINK-7759][TableAPI & SQL] Fix Bug that fieldName with Boolean pref…","user":{"login":"Xpray","id":5170813,"avatar_url":"https://avatars0.githubusercontent.com/u/5170813?v=4","gravatar_id":"","url":"https://api.github.com/users/Xpray","html_url":"https://github.com/Xpray","followers_url":"https://api.github.com/users/Xpray/followers","following_url":"https://api.github.com/users/Xpray/following{/other_user}","gists_url":"https://api.github.com/users/Xpray/gists{/gist_id}","starred_url":"https://api.github.com/users/Xpray/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Xpray/subscriptions","organizations_url":"https://api.github.com/users/Xpray/orgs","repos_url":"https://api.github.com/users/Xpray/repos","events_url":"https://api.github.com/users/Xpray/events{/privacy}","received_events_url":"https://api.github.com/users/Xpray/received_events","type":"User","site_admin":false},"body":"Fix Bug that fieldName with Boolean prefix can't be parsed by ExpressionParser\r\n\r\n## What is the purpose of the change\r\n\r\nFix bug that field names with boolean prefix like \"truex\" or \"FALSE_TARGET\" can't be parsed by `ExpressionParser`\r\n\r\n\r\n## Brief change log\r\n\r\nuse `||| ` instead of ` | ` in `atom` parser, try to match as long as possible, and exchanging of positions of `fieldReference` parser and ` literalExpr ` parser is necessary, because `boolean` can be matched by both parsers, then it's captured by the latter one ` literalExpr ` .\r\n\r\n\r\n## Verifying this change\r\n\r\nThis change added tests and can be verified as follows:\r\n\r\nStringExpressionTest.testFieldWithBooleanPrefix\r\n\r\n## Does this pull request potentially affect one of the following parts:\r\n\r\n  - Dependencies (does it add or upgrade a dependency): no\r\n  - The public API, i.e., is any changed class annotated with `@Public(Evolving)`: no\r\n  - The serializers: no\r\n  - The runtime per-record code paths (performance sensitive):no\r\n  - Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Yarn/Mesos, ZooKeeper: no\r\n\r\n## Documentation\r\n\r\n  - Does this pull request introduce a new feature? no\r\n  - If yes, how is the feature documented? not documented\r\n\r\n","created_at":"2017-10-16T08:27:03Z","updated_at":"2017-10-19T10:22:32Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8a9c662c0cab758b2f791671cc8f432b90b3d636","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/apache/flink/pulls/4829/commits","review_comments_url":"https://api.github.com/repos/apache/flink/pulls/4829/comments","review_comment_url":"https://api.github.com/repos/apache/flink/pulls/comments{/number}","comments_url":"https://api.github.com/repos/apache/flink/issues/4829/comments","statuses_url":"https://api.github.com/repos/apache/flink/statuses/4cdfd18148a1a4e97e078bee6ccf4ba8c20c8034","head":{"label":"Xpray:FLINK-7759","ref":"FLINK-7759","sha":"4cdfd18148a1a4e97e078bee6ccf4ba8c20c8034","user":{"login":"Xpray","id":5170813,"avatar_url":"https://avatars0.githubusercontent.com/u/5170813?v=4","gravatar_id":"","url":"https://api.github.com/users/Xpray","html_url":"https://github.com/Xpray","followers_url":"https://api.github.com/users/Xpray/followers","following_url":"https://api.github.com/users/Xpray/following{/other_user}","gists_url":"https://api.github.com/users/Xpray/gists{/gist_id}","starred_url":"https://api.github.com/users/Xpray/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Xpray/subscriptions","organizations_url":"https://api.github.com/users/Xpray/orgs","repos_url":"https://api.github.com/users/Xpray/repos","events_url":"https://api.github.com/users/Xpray/events{/privacy}","received_events_url":"https://api.github.com/users/Xpray/received_events","type":"User","site_admin":false},"repo":{"id":88852580,"name":"flink","full_name":"Xpray/flink","owner":{"login":"Xpray","id":5170813,"avatar_url":"https://avatars0.githubusercontent.com/u/5170813?v=4","gravatar_id":"","url":"https://api.github.com/users/Xpray","html_url":"https://github.com/Xpray","followers_url":"https://api.github.com/users/Xpray/followers","following_url":"https://api.github.com/users/Xpray/following{/other_user}","gists_url":"https://api.github.com/users/Xpray/gists{/gist_id}","starred_url":"https://api.github.com/users/Xpray/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Xpray/subscriptions","organizations_url":"https://api.github.com/users/Xpray/orgs","repos_url":"https://api.github.com/users/Xpray/repos","events_url":"https://api.github.com/users/Xpray/events{/privacy}","received_events_url":"https://api.github.com/users/Xpray/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Xpray/flink","description":"Mirror of Apache Flink","fork":true,"url":"https://api.github.com/repos/Xpray/flink","forks_url":"https://api.github.com/repos/Xpray/flink/forks","keys_url":"https://api.github.com/repos/Xpray/flink/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Xpray/flink/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Xpray/flink/teams","hooks_url":"https://api.github.com/repos/Xpray/flink/hooks","issue_events_url":"https://api.github.com/repos/Xpray/flink/issues/events{/number}","events_url":"https://api.github.com/repos/Xpray/flink/events","assignees_url":"https://api.github.com/repos/Xpray/flink/assignees{/user}","branches_url":"https://api.github.com/repos/Xpray/flink/branches{/branch}","tags_url":"https://api.github.com/repos/Xpray/flink/tags","blobs_url":"https://api.github.com/repos/Xpray/flink/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Xpray/flink/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Xpray/flink/git/refs{/sha}","trees_url":"https://api.github.com/repos/Xpray/flink/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Xpray/flink/statuses/{sha}","languages_url":"https://api.github.com/repos/Xpray/flink/languages","stargazers_url":"https://api.github.com/repos/Xpray/flink/stargazers","contributors_url":"https://api.github.com/repos/Xpray/flink/contributors","subscribers_url":"https://api.github.com/repos/Xpray/flink/subscribers","subscription_url":"https://api.github.com/repos/Xpray/flink/subscription","commits_url":"https://api.github.com/repos/Xpray/flink/commits{/sha}","git_commits_url":"https://api.github.com/repos/Xpray/flink/git/commits{/sha}","comments_url":"https://api.github.com/repos/Xpray/flink/comments{/number}","issue_comment_url":"https://api.github.com/repos/Xpray/flink/issues/comments{/number}","contents_url":"https://api.github.com/repos/Xpray/flink/contents/{+path}","compare_url":"https://api.github.com/repos/Xpray/flink/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Xpray/flink/merges","archive_url":"https://api.github.com/repos/Xpray/flink/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Xpray/flink/downloads","issues_url":"https://api.github.com/repos/Xpray/flink/issues{/number}","pulls_url":"https://api.github.com/repos/Xpray/flink/pulls{/number}","milestones_url":"https://api.github.com/repos/Xpray/flink/milestones{/number}","notifications_url":"https://api.github.com/repos/Xpray/flink/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Xpray/flink/labels{/name}","releases_url":"https://api.github.com/repos/Xpray/flink/releases{/id}","deployments_url":"https://api.github.com/repos/Xpray/flink/deployments","created_at":"2017-04-20T10:20:40Z","updated_at":"2017-04-20T10:21:06Z","pushed_at":"2017-10-16T08:13:42Z","git_url":"git://github.com/Xpray/flink.git","ssh_url":"git@github.com:Xpray/flink.git","clone_url":"https://github.com/Xpray/flink.git","svn_url":"https://github.com/Xpray/flink","homepage":null,"size":134326,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":3,"forks":0,"open_issues":3,"watchers":0,"default_branch":"master"}},"base":{"label":"apache:master","ref":"master","sha":"b2b94632d88b20a0bfaf00901a485ea705ccec31","user":{"login":"apache","id":47359,"avatar_url":"https://avatars0.githubusercontent.com/u/47359?v=4","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"repo":{"id":20587599,"name":"flink","full_name":"apache/flink","owner":{"login":"apache","id":47359,"avatar_url":"https://avatars0.githubusercontent.com/u/47359?v=4","gravatar_id":"","url":"https://api.github.com/users/apache","html_url":"https://github.com/apache","followers_url":"https://api.github.com/users/apache/followers","following_url":"https://api.github.com/users/apache/following{/other_user}","gists_url":"https://api.github.com/users/apache/gists{/gist_id}","starred_url":"https://api.github.com/users/apache/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/apache/subscriptions","organizations_url":"https://api.github.com/users/apache/orgs","repos_url":"https://api.github.com/users/apache/repos","events_url":"https://api.github.com/users/apache/events{/privacy}","received_events_url":"https://api.github.com/users/apache/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/apache/flink","description":"Mirror of Apache Flink","fork":false,"url":"https://api.github.com/repos/apache/flink","forks_url":"https://api.github.com/repos/apache/flink/forks","keys_url":"https://api.github.com/repos/apache/flink/keys{/key_id}","collaborators_url":"https://api.github.com/repos/apache/flink/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/apache/flink/teams","hooks_url":"https://api.github.com/repos/apache/flink/hooks","issue_events_url":"https://api.github.com/repos/apache/flink/issues/events{/number}","events_url":"https://api.github.com/repos/apache/flink/events","assignees_url":"https://api.github.com/repos/apache/flink/assignees{/user}","branches_url":"https://api.github.com/repos/apache/flink/branches{/branch}","tags_url":"https://api.github.com/repos/apache/flink/tags","blobs_url":"https://api.github.com/repos/apache/flink/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/apache/flink/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/apache/flink/git/refs{/sha}","trees_url":"https://api.github.com/repos/apache/flink/git/trees{/sha}","statuses_url":"https://api.github.com/repos/apache/flink/statuses/{sha}","languages_url":"https://api.github.com/repos/apache/flink/languages","stargazers_url":"https://api.github.com/repos/apache/flink/stargazers","contributors_url":"https://api.github.com/repos/apache/flink/contributors","subscribers_url":"https://api.github.com/repos/apache/flink/subscribers","subscription_url":"https://api.github.com/repos/apache/flink/subscription","commits_url":"https://api.github.com/repos/apache/flink/commits{/sha}","git_commits_url":"https://api.github.com/repos/apache/flink/git/commits{/sha}","comments_url":"https://api.github.com/repos/apache/flink/comments{/number}","issue_comment_url":"https://api.github.com/repos/apache/flink/issues/comments{/number}","contents_url":"https://api.github.com/repos/apache/flink/contents/{+path}","compare_url":"https://api.github.com/repos/apache/flink/compare/{base}...{head}","merges_url":"https://api.github.com/repos/apache/flink/merges","archive_url":"https://api.github.com/repos/apache/flink/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/apache/flink/downloads","issues_url":"https://api.github.com/repos/apache/flink/issues{/number}","pulls_url":"https://api.github.com/repos/apache/flink/pulls{/number}","milestones_url":"https://api.github.com/repos/apache/flink/milestones{/number}","notifications_url":"https://api.github.com/repos/apache/flink/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/apache/flink/labels{/name}","releases_url":"https://api.github.com/repos/apache/flink/releases{/id}","deployments_url":"https://api.github.com/repos/apache/flink/deployments","created_at":"2014-06-07T07:00:10Z","updated_at":"2017-10-19T10:08:00Z","pushed_at":"2017-10-19T10:14:46Z","git_url":"git://github.com/apache/flink.git","ssh_url":"git@github.com:apache/flink.git","clone_url":"https://github.com/apache/flink.git","svn_url":"https://github.com/apache/flink","homepage":null,"size":135663,"stargazers_count":2811,"watchers_count":2811,"language":"Java","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1947,"mirror_url":"git://git.apache.org/flink.git","open_issues_count":332,"forks":1947,"open_issues":332,"watchers":2811,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/apache/flink/pulls/4829"},"html":{"href":"https://github.com/apache/flink/pull/4829"},"issue":{"href":"https://api.github.com/repos/apache/flink/issues/4829"},"comments":{"href":"https://api.github.com/repos/apache/flink/issues/4829/comments"},"review_comments":{"href":"https://api.github.com/repos/apache/flink/pulls/4829/comments"},"review_comment":{"href":"https://api.github.com/repos/apache/flink/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/apache/flink/pulls/4829/commits"},"statuses":{"href":"https://api.github.com/repos/apache/flink/statuses/4cdfd18148a1a4e97e078bee6ccf4ba8c20c8034"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"Xpray"}}