db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t...@apache.org
Subject cvs commit: db-ojb/src/java/org/apache/ojb/broker/accesslayer StatementManager.java
Date Tue, 29 Apr 2003 16:26:56 GMT
thma        2003/04/29 09:26:55

  Modified:    src/java/org/apache/ojb/broker/accesslayer
                        StatementManager.java
  Log:
  be nice to stupid jdbc drivers. Patch by Viktor Schevchik
  
  Revision  Changes    Path
  1.32      +11 -3     db-ojb/src/java/org/apache/ojb/broker/accesslayer/StatementManager.java
  
  Index: StatementManager.java
  ===================================================================
  RCS file: /home/cvs/db-ojb/src/java/org/apache/ojb/broker/accesslayer/StatementManager.java,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -r1.31 -r1.32
  --- StatementManager.java	21 Apr 2003 07:55:57 -0000	1.31
  +++ StatementManager.java	29 Apr 2003 16:26:55 -0000	1.32
  @@ -563,9 +563,13 @@
   		{
   			Object val = values[i];
   			if (val != null)
  -				stmt.setObject(index, values[i]);
  +			{
  +				stmt.setObject(index, values[i], SqlHelper.getSqlTypePk(cld, i));
  +			}
   			else
  +			{
   				stmt.setNull(index, SqlHelper.getSqlTypePk(cld, i));
  +			}
   
   			index++;
   		}
  @@ -575,9 +579,13 @@
   		{
   			Object val = values[i];
   			if (val != null)
  -				stmt.setObject(index, values[i]);
  +			{
  +				stmt.setObject(index, values[i], SqlHelper.getSqlTypeRwNonPk(cld, i));
  +			}
   			else
  +			{
   				stmt.setNull(index, SqlHelper.getSqlTypeRwNonPk(cld, i));
  +			}
   
   			index++;
   		}
  
  
  

Mime
View raw message