aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorTaichi Uragami <backpaper0@gmail.com>2012-04-06 23:52:39 +0900
committerTaichi Uragami <backpaper0@gmail.com>2012-04-06 23:52:39 +0900
commitcb29e503658e2a3339c265651a869fcbe0d5bd7d (patch)
treedadc0427de27e270b83398bfd31282e1991efdaf /src
parent25e92e1b20d58b523c8a1e2090241552bc4489cd (diff)
downloadiciql-cb29e503658e2a3339c265651a869fcbe0d5bd7d.tar.gz
iciql-cb29e503658e2a3339c265651a869fcbe0d5bd7d.zip
Added support for left outer join.
Diffstat (limited to 'src')
-rw-r--r--src/com/iciql/Query.java9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/com/iciql/Query.java b/src/com/iciql/Query.java
index aa0ce4b..9aefe27 100644
--- a/src/com/iciql/Query.java
+++ b/src/com/iciql/Query.java
@@ -845,6 +845,15 @@ public class Query<T> {
return new QueryJoin(this, join);
}
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ public <A> QueryJoin<T> leftJoin(A alias) {
+ TableDefinition<T> def = (TableDefinition<T>) db.define(alias.getClass());
+ SelectTable<T> join = new SelectTable(db, this, alias, true);
+ def.initSelectObject(join, alias, aliasMap);
+ joins.add(join);
+ return new QueryJoin(this, join);
+ }
+
Db getDb() {
return db;
}