Package java.sql

Examples of java.sql.ResultSet.updateObject()


        // Test updateObject() with a java.lang.Boolean on various column types
        rs.moveToInsertRow();
        rs.updateObject("B", Boolean.FALSE); // Used to fail with client driver
        rs.updateObject("I", Boolean.FALSE);
        rs.updateObject("C", Boolean.FALSE);
        rs.insertRow();

        rs.close();

        JDBC.assertFullResultSet(
View Full Code Here


        // setObject() should also fail when the argument is a byte array
        rs = ps.executeQuery();
        rs.moveToInsertRow();
        try {
            rs.updateObject(1, bytes);
            fail("updateObject should fail");
        } catch (SQLException sqle) {
            assertSQLState(ILLEGAL_UPDATE, sqle);
        }
        rs.close();
View Full Code Here

            rs.updateAsciiStream("F13", null, 0L);
            rs.updateCharacterStream("F14", null);
            rs.updateCharacterStream("F14", null, 0);
            rs.updateCharacterStream("F14", null, 0L);
            rs.updateNull("F14");
            rs.updateObject("F15", "object");
            rs.updateObject("F15", "object", 0);
            rs.updateBoolean("F17", false);
            rs.cancelRowUpdates();
            rs.deleteRow();
View Full Code Here

            rs.updateCharacterStream("F14", null);
            rs.updateCharacterStream("F14", null, 0);
            rs.updateCharacterStream("F14", null, 0L);
            rs.updateNull("F14");
            rs.updateObject("F15", "object");
            rs.updateObject("F15", "object", 0);
            rs.updateBoolean("F17", false);
            rs.cancelRowUpdates();
            rs.deleteRow();

            Assert.assertEquals(12, rs.findColumn("F12"));
View Full Code Here

            rs.updateAsciiStream(13, null, 0L);
            rs.updateCharacterStream(14, null);
            rs.updateCharacterStream(14, null, 0);
            rs.updateCharacterStream(14, null, 0L);
            rs.updateNull(14);
            rs.updateObject(15, "object");
            rs.updateObject(15, "object", 0);
            rs.updateBoolean(17, false);
            rs.updateRow();

            JdbcUtils.close(rs);
View Full Code Here

            rs.updateCharacterStream(14, null);
            rs.updateCharacterStream(14, null, 0);
            rs.updateCharacterStream(14, null, 0L);
            rs.updateNull(14);
            rs.updateObject(15, "object");
            rs.updateObject(15, "object", 0);
            rs.updateBoolean(17, false);
            rs.updateRow();

            JdbcUtils.close(rs);
//            conn.rollback(point);
View Full Code Here

                    Iterator<Column> it = columns.keySet().iterator();
                    Column column;
                    while (it.hasNext()) {
                        column = it.next();
                        if (column.isList()) {
                            rs.updateObject(column.columnName(), this.getString((List<?>) columns.get(column)));
                        }
                        else {
                            rs.updateObject(column.columnName(), columns.get(column));
                        }
                    }
View Full Code Here

                        column = it.next();
                        if (column.isList()) {
                            rs.updateObject(column.columnName(), this.getString((List<?>) columns.get(column)));
                        }
                        else {
                            rs.updateObject(column.columnName(), columns.get(column));
                        }
                    }
                    rs.updateRow();
                }
                else {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.