Added supportsTimestampNanos to allow people to work around an ArrayIndexOutOfBoundsException that occurs when using multiple timestamp columns with version 9.2+ of the Oracle JDBC driver and version less than 9.2 of the Oracle server.

git-svn-id: https://svn.apache.org/repos/asf/incubator/openjpa/trunk@453715 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Marc Prud'hommeaux 2006-10-06 18:03:50 +00:00
parent 27e8bd4849
commit b25dfe66f4
1 changed files with 6 additions and 1 deletions

View File

@ -153,6 +153,7 @@ public class DBDictionary
public int maxIndexNameLength = 128;
public int maxIndexesPerTable = Integer.MAX_VALUE;
public boolean supportsForeignKeys = true;
public boolean supportsTimestampNanos = true;
public boolean supportsUniqueConstraints = true;
public boolean supportsDeferredConstraints = true;
public boolean supportsRestrictDeleteAction = true;
@ -1040,7 +1041,11 @@ public class DBDictionary
val.setTime(val.getTime() + 1000);
nanos = 0;
}
if (supportsTimestampNanos)
val.setNanos(nanos);
else
val.setNanos(0);
if (cal == null)
stmnt.setTimestamp(idx, val);