diff options
author | Brian S. O'Neill <bronee@gmail.com> | 2006-11-04 00:27:28 +0000 |
---|---|---|
committer | Brian S. O'Neill <bronee@gmail.com> | 2006-11-04 00:27:28 +0000 |
commit | 9e4cd7e3af4ff5326fcb7a1dde3861f64badab41 (patch) | |
tree | f325407c10161f6059beffc8e3e713518ebefe92 /src/main/java/com/amazon/carbonado/qe | |
parent | 37f9eb4388bda8908a1eab2cba487d4afc3d94bd (diff) |
Fixed exception when printing join plan with blank parameters.
Diffstat (limited to 'src/main/java/com/amazon/carbonado/qe')
4 files changed, 3 insertions, 11 deletions
diff --git a/src/main/java/com/amazon/carbonado/qe/DelegatedQueryExecutor.java b/src/main/java/com/amazon/carbonado/qe/DelegatedQueryExecutor.java index 1fe3ba8..b4bc0a3 100644 --- a/src/main/java/com/amazon/carbonado/qe/DelegatedQueryExecutor.java +++ b/src/main/java/com/amazon/carbonado/qe/DelegatedQueryExecutor.java @@ -126,14 +126,10 @@ public class DelegatedQueryExecutor<S extends Storable> implements QueryExecutor }
private Query<S> applyFilterValues(FilterValues<S> values) {
- // FIXME: figure out how to transfer values directly to query.
-
Query<S> query = mQuery;
Filter<S> filter = query.getFilter();
- // FIXME: this code can get confused if filter has constants.
if (values != null && filter != null && query.getBlankParameterCount() != 0) {
- // FIXME: throws exception if not all values supplied
- query = query.withValues(values.getValuesFor(filter));
+ query = query.withValues(values.getSuppliedValuesFor(filter));
}
return query;
}
diff --git a/src/main/java/com/amazon/carbonado/qe/JoinedQueryExecutor.java b/src/main/java/com/amazon/carbonado/qe/JoinedQueryExecutor.java index f3399a5..00ffda3 100644 --- a/src/main/java/com/amazon/carbonado/qe/JoinedQueryExecutor.java +++ b/src/main/java/com/amazon/carbonado/qe/JoinedQueryExecutor.java @@ -595,8 +595,8 @@ public class JoinedQueryExecutor<S extends Storable, T extends Storable> if (values == null) {
return null;
}
- // FIXME: throws exception if not all values supplied
- return mOuterLoopFilterValues.withValues(values.getValuesFor(mSourceFilterAsFromTarget));
+ return mOuterLoopFilterValues
+ .withValues(values.getSuppliedValuesFor(mSourceFilterAsFromTarget));
}
@SuppressWarnings("unused")
diff --git a/src/main/java/com/amazon/carbonado/qe/StandardQuery.java b/src/main/java/com/amazon/carbonado/qe/StandardQuery.java index d7f5263..c1038c7 100644 --- a/src/main/java/com/amazon/carbonado/qe/StandardQuery.java +++ b/src/main/java/com/amazon/carbonado/qe/StandardQuery.java @@ -162,8 +162,6 @@ public abstract class StandardQuery<S extends Storable> extends AbstractQuery<S> if (mValues == null) {
return new EmptyQuery<S>(queryFactory(), mOrdering);
}
- // FIXME: Just like with DelegatedQueryExecutor, need a better way of
- // transfering values.
FilterValues<S> newValues = mValues.getFilter().not()
.initialFilterValues().withValues(mValues.getSuppliedValues());
return createQuery(newValues, mOrdering);
diff --git a/src/main/java/com/amazon/carbonado/qe/StandardQueryFactory.java b/src/main/java/com/amazon/carbonado/qe/StandardQueryFactory.java index c7ac720..06767c5 100644 --- a/src/main/java/com/amazon/carbonado/qe/StandardQueryFactory.java +++ b/src/main/java/com/amazon/carbonado/qe/StandardQueryFactory.java @@ -157,8 +157,6 @@ public abstract class StandardQueryFactory<S extends Storable> implements QueryF if (values == null) {
query = query(Filter.getOpenFilter(mType), ordering);
} else {
- // FIXME: Just like with DelegatedQueryExecutor, need a better way
- // of transfering values.
query = query(values.getFilter(), ordering).withValues(values.getSuppliedValues());
}
return query;
|