diff options
author | James Ahlborn <jtahlborn@yahoo.com> | 2017-06-26 00:28:32 +0000 |
---|---|---|
committer | James Ahlborn <jtahlborn@yahoo.com> | 2017-06-26 00:28:32 +0000 |
commit | c1eb52f4f69ea9320f67f5f7fc4df1b21467d481 (patch) | |
tree | 3798e1c289a124a420787a3b0612ec477c4df8de /src/main/java | |
parent | c3d229ff33263f70358d45c8361fcf1ab689a5c7 (diff) | |
download | jackcess-c1eb52f4f69ea9320f67f5f7fc4df1b21467d481.tar.gz jackcess-c1eb52f4f69ea9320f67f5f7fc4df1b21467d481.zip |
handle missing table name for join expression
git-svn-id: https://svn.code.sf.net/p/jackcess/code/jackcess/trunk@1105 f203690c-595d-4dc9-a70b-905162fa7fd2
Diffstat (limited to 'src/main/java')
-rw-r--r-- | src/main/java/com/healthmarketscience/jackcess/impl/query/QueryImpl.java | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/main/java/com/healthmarketscience/jackcess/impl/query/QueryImpl.java b/src/main/java/com/healthmarketscience/jackcess/impl/query/QueryImpl.java index a9fd5e6..151fd30 100644 --- a/src/main/java/com/healthmarketscience/jackcess/impl/query/QueryImpl.java +++ b/src/main/java/com/healthmarketscience/jackcess/impl/query/QueryImpl.java @@ -267,7 +267,7 @@ public abstract class QueryImpl implements Query return result; } - private Join getJoinExpr(String table, List<Join> joinExprs) + private static Join getJoinExpr(String table, List<Join> joinExprs) { for(Iterator<Join> iter = joinExprs.iterator(); iter.hasNext(); ) { Join joinExpr = iter.next(); @@ -276,8 +276,9 @@ public abstract class QueryImpl implements Query return joinExpr; } } - throw new IllegalStateException(withErrorContext( - "Cannot find join table " + table)); + // just use the table name as is + return new Join(table, toOptionalQuotedExpr(new StringBuilder(), + table, true).toString()); } private Collection<List<Row>> combineJoins(List<Row> joins) |