| java.lang.Object com.knowgate.datacopy.CopyRegisters
CopyRegisters | public class CopyRegisters (Code) | | author: Sergio Montoro Ten version: 2.0 |
Method Summary | |
public int | append(Connection oOrigin, Connection oTarget, String sOriginTable, String sTargetTable, String sWhere) | public Object | cast(Object oOrigin, int iOriginType, int iTargetType) | public int | insert(Connection oOrigin, Connection oTarget, String sOriginTable, String sTargetTable, String sWhere) | public int | replace(Connection oOrigin, Connection oTarget, String sOriginTable, String sTargetTable, String sWhere) |
FETCH_SIZE | public static int FETCH_SIZE(Code) | | |
CopyRegisters | public CopyRegisters()(Code) | | |
append | public int append(Connection oOrigin, Connection oTarget, String sOriginTable, String sTargetTable, String sWhere) throws SQLException(Code) | | Append registers from origin table to target table.
Registers not present at target table will be inserted from origin table and those present will be updated
Parameters: oOrigin - JDBC Origin Connection Parameters: oTarget - JDBC Target Connection Parameters: sOriginTable - Origin Table Name Parameters: sTargetTable - Target Table Name Parameters: sWhere - SQL filter clause to be applied at origin fron retrieving only a register subset Number of replaced rows throws: SQLException - |
insert | public int insert(Connection oOrigin, Connection oTarget, String sOriginTable, String sTargetTable, String sWhere) throws SQLException(Code) | | Insert registers from origin table to target table.
Parameters: oOrigin - JDBC Origin Connection Parameters: oTarget - JDBC Target Connection Parameters: sOriginTable - Origin Table Name Parameters: sTargetTable - Target Table Name Parameters: sWhere - SQL filter clause to be applied at origin fron retrieving only a register subset Number of inserted rows throws: SQLException - A duplicated primary key exception is thrown if any inserted register already exists at target table |
replace | public int replace(Connection oOrigin, Connection oTarget, String sOriginTable, String sTargetTable, String sWhere) throws SQLException(Code) | | Replace registers from origin table to target table.
Registers not already present at target table will not be inserted from origin table
Parameters: oOrigin - JDBC Origin Connection Parameters: oTarget - JDBC Target Connection Parameters: sOriginTable - Origin Table Name Parameters: sTargetTable - Target Table Name Parameters: sWhere - SQL filter clause to be applied at origin fron retrieving only a register subset Number of replaced rows throws: SQLException - |
|
|