Commits

Anonymous committed cfd5de0

Comments (0)

Files changed (1)

src/java/com/opensymphony/module/propertyset/database/JDBCPropertySet.java

     protected String globalKey;
     protected String tableName;
     protected boolean closeConnWhenDone = false;
-    private String driverName;
-    private String productName;
 
     //~ Methods ////////////////////////////////////////////////////////////////
 
     }
 
     private void setValues(PreparedStatement ps, int type, String key, Object value) throws SQLException, PropertyException {
-        // Patched by Edson Richter for MS SQL Server JDBC Support!
-        if ((driverName == null) || (productName == null)) {
-            try {
-                this.driverName = ps.getConnection().getMetaData().getDriverName().toUpperCase();
-                this.productName = ps.getConnection().getMetaData().getDatabaseProductName().toUpperCase();
-            } catch (Exception e) {
-                this.driverName = "";
-            }
-        }
-
         ps.setNull(1, Types.VARCHAR);
         ps.setNull(2, Types.TIMESTAMP);
-
-        // Patched by Edson Richter for MS SQL Server JDBC Support!
-        // Oracle support suggestion also Michael G. Slack
-        if ((this.driverName.indexOf("SQLSERVER") > -1) || (this.driverName.indexOf("ORACLE") > -1)) {
-            ps.setNull(3, Types.BINARY);
-        } else if ((this.driverName.indexOf("SYBASE") > -1) || (this.productName.indexOf("SYBASE") > -1)) {
-            ps.setNull(3, Types.VARBINARY);
-        } else {
-            ps.setNull(3, Types.BLOB);
-        }
-
+        ps.setNull(3, Types.VARBINARY);
         ps.setNull(4, Types.FLOAT);
         ps.setNull(5, Types.NUMERIC);
         ps.setInt(6, type);