You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@tajo.apache.org by eminency <gi...@git.apache.org> on 2014/09/16 14:32:06 UTC
[GitHub] tajo pull request: TAJO-948: INSERT INTO' statement to non existen...
GitHub user eminency opened a pull request:
https://github.com/apache/tajo/pull/142
TAJO-948: INSERT INTO' statement to non existence table casuses NPE
The cause is there is no part to check if the table instance is null before it's used.
Please review if the changeset is appropriate.
Thanks.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/eminency/tajo TAJO-948
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/tajo/pull/142.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #142
----
commit 0b96b4cf26bd24f108ff7e268e1c3199693cbc7f
Author: Jongyoung Park <em...@gmail.com>
Date: 2014-09-16T09:57:15Z
Checking null code is added to verify table existence
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] tajo pull request: TAJO-948: 'INSERT INTO' statement to non existe...
Posted by hyunsik <gi...@git.apache.org>.
Github user hyunsik commented on a diff in the pull request:
https://github.com/apache/tajo/pull/142#discussion_r17604055
--- Diff: tajo-core/src/main/java/org/apache/tajo/engine/planner/PreLogicalPlanVerifier.java ---
@@ -254,6 +254,10 @@ public Expr visitInsert(Context context, Stack<Expr> stack, Insert expr) throws
}
TableDesc table = catalog.getTableDesc(qualifiedName);
+ if (table == null) {
+ context.state.addVerification("It seems target table doesn't exist");
--- End diff --
The bug fix looks correct. But, I have one suggestion about the message. The other similar cases use ```relation "%s" does not exist```. Could you change the message for consistency?
You can see the similar case at https://github.com/eminency/tajo/blob/TAJO-948/tajo-core/src/main/java/org/apache/tajo/engine/planner/PreLogicalPlanVerifier.java#L134
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] tajo pull request: TAJO-948: 'INSERT INTO' statement to non existe...
Posted by hyunsik <gi...@git.apache.org>.
Github user hyunsik commented on the pull request:
https://github.com/apache/tajo/pull/142#issuecomment-55923268
+1
The patch looks good to me.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] tajo pull request: TAJO-948: 'INSERT INTO' statement to non existe...
Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:
https://github.com/apache/tajo/pull/142
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] tajo pull request: TAJO-948: 'INSERT INTO' statement to non existe...
Posted by eminency <gi...@git.apache.org>.
Github user eminency commented on the pull request:
https://github.com/apache/tajo/pull/142#issuecomment-55751677
@hyunsik ,
Your line comment sounds like a good suggestion.
I will touch further.
Thanks.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] tajo pull request: TAJO-948: 'INSERT INTO' statement to non existe...
Posted by eminency <gi...@git.apache.org>.
Github user eminency commented on the pull request:
https://github.com/apache/tajo/pull/142#issuecomment-55852967
The message was refined.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---