public CopyOut copyOut(String sql) throws SQLException { CopyOperation op = queryExecutor.startCopy(sql, connection.getAutoCommit()); if (op == null || op instanceof CopyOut) { return (CopyOut) op; } else { op.cancelCopy(); throw new PSQLException(GT.tr("Requested CopyOut but got {0}", op.getClass().getName()), PSQLState.WRONG_OBJECT_TYPE); } }
public CopyIn copyIn(String sql) throws SQLException { CopyOperation op = queryExecutor.startCopy(sql, connection.getAutoCommit()); if (op == null || op instanceof CopyIn) { return (CopyIn) op; } else { op.cancelCopy(); throw new PSQLException(GT.tr("Requested CopyIn but got {0}", op.getClass().getName()), PSQLState.WRONG_OBJECT_TYPE); } }
public CopyDual copyDual(String sql) throws SQLException { CopyOperation op = queryExecutor.startCopy(sql, connection.getAutoCommit()); if (op == null || op instanceof CopyDual) { return (CopyDual) op; } else { op.cancelCopy(); throw new PSQLException(GT.tr("Requested CopyDual but got {0}", op.getClass().getName()), PSQLState.WRONG_OBJECT_TYPE); } }
public CopyOut copyOut(String sql) throws SQLException { CopyOperation op = null; try { op = queryExecutor.startCopy(sql, connection.getAutoCommit()); return (CopyOut) op; } catch(ClassCastException cce) { op.cancelCopy(); throw new PSQLException(GT.tr("Requested CopyOut but got {0}", op.getClass().getName()), PSQLState.WRONG_OBJECT_TYPE, cce); } }
public CopyIn copyIn(String sql) throws SQLException { CopyOperation op = null; try { op = queryExecutor.startCopy(sql, connection.getAutoCommit()); return (CopyIn) op; } catch(ClassCastException cce) { op.cancelCopy(); throw new PSQLException(GT.tr("Requested CopyIn but got {0}", op.getClass().getName()), PSQLState.WRONG_OBJECT_TYPE, cce); } }
public CopyOut copyOut(String sql) throws SQLException { CopyOperation op = null; try { op = queryExecutor.startCopy(sql, connection.getAutoCommit()); return (CopyOut) op; } catch(ClassCastException cce) { op.cancelCopy(); throw new PSQLException(GT.tr("Requested CopyOut but got {0}", op.getClass().getName()), PSQLState.WRONG_OBJECT_TYPE, cce); } }
public CopyIn copyIn(String sql) throws SQLException { CopyOperation op = null; try { op = queryExecutor.startCopy(sql, connection.getAutoCommit()); return (CopyIn) op; } catch(ClassCastException cce) { op.cancelCopy(); throw new PSQLException(GT.tr("Requested CopyIn but got {0}", op.getClass().getName()), PSQLState.WRONG_OBJECT_TYPE, cce); } }
public CopyOut copyOut(String sql) throws SQLException { CopyOperation op = null; try { op = queryExecutor.startCopy(sql, connection.getAutoCommit()); return (CopyOut) op; } catch(ClassCastException cce) { op.cancelCopy(); throw new PSQLException(GT.tr("Requested CopyOut but got {0}", op.getClass().getName()), PSQLState.WRONG_OBJECT_TYPE, cce); } }
public CopyIn copyIn(String sql) throws SQLException { CopyOperation op = null; try { op = queryExecutor.startCopy(sql, connection.getAutoCommit()); return (CopyIn) op; } catch(ClassCastException cce) { op.cancelCopy(); throw new PSQLException(GT.tr("Requested CopyIn but got {0}", op.getClass().getName()), PSQLState.WRONG_OBJECT_TYPE, cce); } }