#382 - ENH: Add support for @History using Oracle Total Recall ... for 'as of' queries

This commit is contained in:
Robin Bygrave committed 2015-08-18 22:19:55 +12:00
1 parent 18aeedc153
commit 10937de24b
13 files changed
+234 -52

No files matched your search

@@ -28,12 +28,15 @@ public class Binder {
private final int asOfBindCount;
private final boolean bindAsOfWithFromClause;
/**
* Set the PreparedStatement with which to bind variables to.
*/
public Binder(TypeManager typeManager, int asOfBindCount) {
public Binder(TypeManager typeManager, int asOfBindCount, boolean bindAsOfWithFromClause) {
this.typeManager = typeManager;
this.asOfBindCount = asOfBindCount;
this.bindAsOfWithFromClause = bindAsOfWithFromClause;
}
/**
@@ -43,6 +46,15 @@ public class Binder {
return asOfBindCount;
}
/**
* Return true if the 'as of' predicates are in the from/join clause in which case the timestamp is
* bound early (before all the other predicates ala Oracle). Return false if the 'as of' predicates are
* appended to the end of the predicates and the timestamp is bound last (Postgres, MySql).
*/
public boolean isBindAsOfWithFromClause() {
return bindAsOfWithFromClause;
}
/**
* Bind the values to the Prepared Statement.
*/