diff --git a/dbclient/jdbc/src/main/java/io/helidon/dbclient/jdbc/JdbcStatement.java b/dbclient/jdbc/src/main/java/io/helidon/dbclient/jdbc/JdbcStatement.java index 0d0f3f11629..4420dc66429 100644 --- a/dbclient/jdbc/src/main/java/io/helidon/dbclient/jdbc/JdbcStatement.java +++ b/dbclient/jdbc/src/main/java/io/helidon/dbclient/jdbc/JdbcStatement.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2019, 2020 Oracle and/or its affiliates. + * Copyright (c) 2019, 2021 Oracle and/or its affiliates. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -116,10 +116,6 @@ private PreparedStatement prepareNamedStatement(Connection connection, LOGGER.finest(() -> String.format("Converted statement: %s", jdbcStatement)); preparedStatement = connection.prepareStatement(jdbcStatement); List namesOrder = parser.namesOrder(); - // SQL statement and provided parameters integrity check - if (namesOrder.size() > parameters.size()) { - throw new DbClientException(namedStatementErrorMessage(namesOrder, parameters)); - } // Set parameters into prepared statement int i = 1; for (String name : namesOrder) { diff --git a/dbclient/jdbc/src/test/java/io/helidon/dbclient/jdbc/JdbcStatementTest.java b/dbclient/jdbc/src/test/java/io/helidon/dbclient/jdbc/JdbcStatementTest.java new file mode 100644 index 00000000000..ac198127186 --- /dev/null +++ b/dbclient/jdbc/src/test/java/io/helidon/dbclient/jdbc/JdbcStatementTest.java @@ -0,0 +1,113 @@ +/* + * Copyright (c) 2021 Oracle and/or its affiliates. All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package io.helidon.dbclient.jdbc; + +import java.sql.Connection; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.concurrent.CompletableFuture; + +import io.helidon.dbclient.DbClientServiceContext; +import io.helidon.dbclient.DbStatementType; +import io.helidon.dbclient.common.DbStatementContext; +import io.helidon.dbclient.jdbc.SqlPreparedStatementMock.ParInfo; + +import org.junit.jupiter.api.Test; + +import static org.hamcrest.MatcherAssert.assertThat; +import static org.hamcrest.Matchers.equalTo; + +/** + * JDBC statement tests + */ +public class JdbcStatementTest { + + /** + * Issue #2599: Named parameters should be usable more than once in a statement. + * Verify parameters order returned by parser. + * Verify how parameters were set in PreparedStatement. + */ + @Test + void testMultipleNamedParameterUsage() { + // Data mockup + Connection conn = new SqlConnectionMock(); + CompletableFuture connFuture = new CompletableFuture<>(); + connFuture.complete(conn); + Map params = new HashMap<>(3); + params.put("name", "Name"); + // Let's try other tham Integer type + params.put("count", (short) 5); + params.put("id", 12); + JdbcExecuteContext execCtx = JdbcExecuteContext.jdbcBuilder() + .dbType("Test") + .connection(connFuture) + .build(); + DbStatementContext stmtCtx = DbStatementContext.builder() + .statementName("test") + .statementType(DbStatementType.UPDATE) + .statementText("UPDATE TestTable SET name1=:name, name2=:name, count1=:count, count2=:count, count3=:count WHERE id=:id") + .build(); + JdbcStatementDml dml = new JdbcStatementDml(execCtx, stmtCtx); + DbClientServiceContext dbContext = DbClientServiceContext.create(dml.dbType()); + dbContext.statement(stmtCtx.statement(), params); + // Contains statement params setting info. + JdbcStatement.Parser parser = new JdbcStatement.Parser(stmtCtx.statement()); + String jdbcStatement = parser.convert(); + // Parsed order of params. + List namesOrder = parser.namesOrder(); + // Verify that parsed names order matches DML statement + assertThat(namesOrder.get(0), equalTo("name")); + assertThat(namesOrder.get(1), equalTo("name")); + assertThat(namesOrder.get(2), equalTo("count")); + assertThat(namesOrder.get(3), equalTo("count")); + assertThat(namesOrder.get(4), equalTo("count")); + assertThat(namesOrder.get(5), equalTo("id")); + // Build statement mockup from statement context with multiple parameters + // It shall not fail when Issue #2599 is fixed + SqlPreparedStatementMock stmt = (SqlPreparedStatementMock)dml.build(conn, dbContext); + // Verify parameters set in statement mockup + Map stmtParams = stmt.params(); + // Parameters count shall be 6 + assertThat(stmtParams.size(), equalTo(6)); + // 1st assignment name1=:name + final ParInfo info1 = stmtParams.get(1); + assertThat(info1.value(), equalTo("Name")); + assertThat(info1.cls(), equalTo(String.class)); + // 2nd assignment name2=:name + final ParInfo info2 = stmtParams.get(2); + assertThat(info2.value(), equalTo("Name")); + assertThat(info2.cls(), equalTo(String.class)); + // 3rd assignment count1=:count + final ParInfo info3 = stmtParams.get(3); + assertThat(info3.value(), equalTo((short) 5)); + assertThat(info3.cls(), equalTo(Short.class)); + // 4th assignment count2=:count + final ParInfo info4 = stmtParams.get(4); + assertThat(info4.value(), equalTo((short) 5)); + assertThat(info4.cls(), equalTo(Short.class)); + // 5th assignment count3=:count + final ParInfo info5 = stmtParams.get(5); + assertThat(info5.value(), equalTo((short) 5)); + assertThat(info5.cls(), equalTo(Short.class)); + // 6th assignment id=:id + final ParInfo info6 = stmtParams.get(6); + assertThat(info6.value(), equalTo(12)); + assertThat(info6.cls(), equalTo(Integer.class)); + } + +} diff --git a/dbclient/jdbc/src/test/java/io/helidon/dbclient/jdbc/SqlConnectionMock.java b/dbclient/jdbc/src/test/java/io/helidon/dbclient/jdbc/SqlConnectionMock.java new file mode 100644 index 00000000000..9b065fb5252 --- /dev/null +++ b/dbclient/jdbc/src/test/java/io/helidon/dbclient/jdbc/SqlConnectionMock.java @@ -0,0 +1,313 @@ +/* + * Copyright (c) 2021 Oracle and/or its affiliates. All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package io.helidon.dbclient.jdbc; + +import java.sql.Array; +import java.sql.Blob; +import java.sql.CallableStatement; +import java.sql.Clob; +import java.sql.Connection; +import java.sql.DatabaseMetaData; +import java.sql.NClob; +import java.sql.PreparedStatement; +import java.sql.SQLClientInfoException; +import java.sql.SQLException; +import java.sql.SQLWarning; +import java.sql.SQLXML; +import java.sql.Savepoint; +import java.sql.Statement; +import java.sql.Struct; +import java.util.Map; +import java.util.Properties; +import java.util.concurrent.Executor; + +/** + * SQL Connection mockup which returns PreparedStatement mockup. + */ +class SqlConnectionMock implements Connection { + + @Override + public Statement createStatement() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public PreparedStatement prepareStatement(String sql) throws SQLException { + return new SqlPreparedStatementMock(); + } + + @Override + public CallableStatement prepareCall(String sql) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public String nativeSQL(String sql) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setAutoCommit(boolean autoCommit) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean getAutoCommit() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void commit() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void rollback() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void close() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean isClosed() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public DatabaseMetaData getMetaData() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setReadOnly(boolean readOnly) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean isReadOnly() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setCatalog(String catalog) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public String getCatalog() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setTransactionIsolation(int level) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int getTransactionIsolation() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public SQLWarning getWarnings() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void clearWarnings() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public Statement createStatement(int resultSetType, int resultSetConcurrency) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public PreparedStatement prepareStatement(String sql, int resultSetType, int resultSetConcurrency) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public CallableStatement prepareCall(String sql, int resultSetType, int resultSetConcurrency) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public Map> getTypeMap() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setTypeMap(Map> map) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setHoldability(int holdability) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int getHoldability() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public Savepoint setSavepoint() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public Savepoint setSavepoint(String name) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void rollback(Savepoint savepoint) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void releaseSavepoint(Savepoint savepoint) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public Statement createStatement(int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public PreparedStatement prepareStatement(String sql, int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public CallableStatement prepareCall(String sql, int resultSetType, int resultSetConcurrency, int resultSetHoldability) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public PreparedStatement prepareStatement(String sql, int autoGeneratedKeys) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public PreparedStatement prepareStatement(String sql, int[] columnIndexes) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public PreparedStatement prepareStatement(String sql, String[] columnNames) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public Clob createClob() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public Blob createBlob() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public NClob createNClob() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public SQLXML createSQLXML() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean isValid(int timeout) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setClientInfo(String name, String value) throws SQLClientInfoException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setClientInfo(Properties properties) throws SQLClientInfoException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public String getClientInfo(String name) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public Properties getClientInfo() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public Array createArrayOf(String typeName, Object[] elements) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public Struct createStruct(String typeName, Object[] attributes) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setSchema(String schema) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public String getSchema() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void abort(Executor executor) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setNetworkTimeout(Executor executor, int milliseconds) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int getNetworkTimeout() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public T unwrap(Class iface) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean isWrapperFor(Class iface) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + +} diff --git a/dbclient/jdbc/src/test/java/io/helidon/dbclient/jdbc/SqlPreparedStatementMock.java b/dbclient/jdbc/src/test/java/io/helidon/dbclient/jdbc/SqlPreparedStatementMock.java new file mode 100644 index 00000000000..cbd6fe0ba75 --- /dev/null +++ b/dbclient/jdbc/src/test/java/io/helidon/dbclient/jdbc/SqlPreparedStatementMock.java @@ -0,0 +1,574 @@ +/* + * Copyright (c) 2021 Oracle and/or its affiliates. All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package io.helidon.dbclient.jdbc; + +import java.io.InputStream; +import java.io.Reader; +import java.math.BigDecimal; +import java.net.URL; +import java.sql.Array; +import java.sql.Blob; +import java.sql.Clob; +import java.sql.Connection; +import java.sql.Date; +import java.sql.NClob; +import java.sql.ParameterMetaData; +import java.sql.PreparedStatement; +import java.sql.Ref; +import java.sql.ResultSet; +import java.sql.ResultSetMetaData; +import java.sql.RowId; +import java.sql.SQLException; +import java.sql.SQLWarning; +import java.sql.SQLXML; +import java.sql.Time; +import java.sql.Timestamp; +import java.util.Calendar; +import java.util.HashMap; +import java.util.Map; + +/** + * SQL PreparedStatement mockup to verify how parameters were set. + */ +class SqlPreparedStatementMock implements PreparedStatement { + + static final class ParInfo { + + private final Class cls; + private final Object value; + + ParInfo(final Class cls, final Object value) { + this.cls = cls; + this.value = value; + } + + Class cls() { + return cls; + } + + Object value() { + return value; + } + } + + /** + * Parameter settings info. + */ + Map params = new HashMap<>(); + + private void addParInfo(final int parameterIndex, final Class cls, final Object value) { + params.put(parameterIndex, new ParInfo(cls, value)); + } + + Map params() { + return params; + } + + @Override + public ResultSet executeQuery() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int executeUpdate() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setNull(int parameterIndex, int sqlType) throws SQLException { + addParInfo(parameterIndex, null, null); + } + + @Override + public void setBoolean(int parameterIndex, boolean x) throws SQLException { + addParInfo(parameterIndex, Boolean.class, x); + } + + @Override + public void setByte(int parameterIndex, byte x) throws SQLException { + addParInfo(parameterIndex, Byte.class, x); + } + + @Override + public void setShort(int parameterIndex, short x) throws SQLException { + addParInfo(parameterIndex, Short.class, x); + } + + @Override + public void setInt(int parameterIndex, int x) throws SQLException { + addParInfo(parameterIndex, Integer.class, x); + } + + @Override + public void setLong(int parameterIndex, long x) throws SQLException { + addParInfo(parameterIndex, Long.class, x); + } + + @Override + public void setFloat(int parameterIndex, float x) throws SQLException { + addParInfo(parameterIndex, Float.class, x); + } + + @Override + public void setDouble(int parameterIndex, double x) throws SQLException { + addParInfo(parameterIndex, Double.class, x); + } + + @Override + public void setBigDecimal(int parameterIndex, BigDecimal x) throws SQLException { + addParInfo(parameterIndex, Boolean.class, x); + } + + @Override + public void setString(int parameterIndex, String x) throws SQLException { + addParInfo(parameterIndex, String.class, x); + } + + @Override + public void setBytes(int parameterIndex, byte[] x) throws SQLException { + addParInfo(parameterIndex, byte[].class, x); + } + + @Override + public void setDate(int parameterIndex, Date x) throws SQLException { + addParInfo(parameterIndex, Date.class, x); + } + + @Override + public void setTime(int parameterIndex, Time x) throws SQLException { + addParInfo(parameterIndex, Time.class, x); + } + + @Override + public void setTimestamp(int parameterIndex, Timestamp x) throws SQLException { + addParInfo(parameterIndex, Timestamp.class, x); + } + + @Override + public void setAsciiStream(int parameterIndex, InputStream x, int length) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setUnicodeStream(int parameterIndex, InputStream x, int length) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setBinaryStream(int parameterIndex, InputStream x, int length) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void clearParameters() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setObject(int parameterIndex, Object x, int targetSqlType) throws SQLException { + addParInfo(parameterIndex, x.getClass(), x); + } + + @Override + public void setObject(int parameterIndex, Object x) throws SQLException { + addParInfo(parameterIndex, x.getClass(), x); + } + + @Override + public boolean execute() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void addBatch() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setCharacterStream(int parameterIndex, Reader reader, int length) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setRef(int parameterIndex, Ref x) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setBlob(int parameterIndex, Blob x) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setClob(int parameterIndex, Clob x) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setArray(int parameterIndex, Array x) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public ResultSetMetaData getMetaData() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setDate(int parameterIndex, Date x, Calendar cal) throws SQLException { + addParInfo(parameterIndex, Date.class, x); + } + + @Override + public void setTime(int parameterIndex, Time x, Calendar cal) throws SQLException { + addParInfo(parameterIndex, Time.class, x); + } + + @Override + public void setTimestamp(int parameterIndex, Timestamp x, Calendar cal) throws SQLException { + addParInfo(parameterIndex, Timestamp.class, x); + } + + @Override + public void setNull(int parameterIndex, int sqlType, String typeName) throws SQLException { + addParInfo(parameterIndex, null, null); + } + + @Override + public void setURL(int parameterIndex, URL x) throws SQLException { + addParInfo(parameterIndex, URL.class, x); + } + + @Override + public ParameterMetaData getParameterMetaData() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setRowId(int parameterIndex, RowId x) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setNString(int parameterIndex, String value) throws SQLException { + addParInfo(parameterIndex, String.class, value); + } + + @Override + public void setNCharacterStream(int parameterIndex, Reader value, long length) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setNClob(int parameterIndex, NClob value) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setClob(int parameterIndex, Reader reader, long length) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setBlob(int parameterIndex, InputStream inputStream, long length) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setNClob(int parameterIndex, Reader reader, long length) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setSQLXML(int parameterIndex, SQLXML xmlObject) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setObject(int parameterIndex, Object x, int targetSqlType, int scaleOrLength) throws SQLException { + } + + @Override + public void setAsciiStream(int parameterIndex, InputStream x, long length) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setBinaryStream(int parameterIndex, InputStream x, long length) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setCharacterStream(int parameterIndex, Reader reader, long length) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setAsciiStream(int parameterIndex, InputStream x) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setBinaryStream(int parameterIndex, InputStream x) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setCharacterStream(int parameterIndex, Reader reader) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setNCharacterStream(int parameterIndex, Reader value) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setClob(int parameterIndex, Reader reader) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setBlob(int parameterIndex, InputStream inputStream) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setNClob(int parameterIndex, Reader reader) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public ResultSet executeQuery(String sql) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int executeUpdate(String sql) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void close() throws SQLException { + } + + @Override + public int getMaxFieldSize() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setMaxFieldSize(int max) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int getMaxRows() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setMaxRows(int max) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setEscapeProcessing(boolean enable) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int getQueryTimeout() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setQueryTimeout(int seconds) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void cancel() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public SQLWarning getWarnings() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void clearWarnings() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setCursorName(String name) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean execute(String sql) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public ResultSet getResultSet() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int getUpdateCount() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean getMoreResults() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setFetchDirection(int direction) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int getFetchDirection() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setFetchSize(int rows) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int getFetchSize() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int getResultSetConcurrency() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int getResultSetType() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void addBatch(String sql) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void clearBatch() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int[] executeBatch() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public Connection getConnection() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean getMoreResults(int current) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public ResultSet getGeneratedKeys() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int executeUpdate(String sql, int autoGeneratedKeys) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int executeUpdate(String sql, int[] columnIndexes) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int executeUpdate(String sql, String[] columnNames) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean execute(String sql, int autoGeneratedKeys) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean execute(String sql, int[] columnIndexes) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean execute(String sql, String[] columnNames) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public int getResultSetHoldability() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean isClosed() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void setPoolable(boolean poolable) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean isPoolable() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public void closeOnCompletion() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean isCloseOnCompletion() throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public T unwrap(Class iface) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + + @Override + public boolean isWrapperFor(Class iface) throws SQLException { + throw new UnsupportedOperationException("Not supported yet."); + } + +}