Example usage for java.sql Types BIGINT

List of usage examples for java.sql Types BIGINT

Introduction

In this page you can find the example usage for java.sql Types BIGINT.

Prototype

int BIGINT

To view the source code for java.sql Types BIGINT.

Click Source Link

Document

The constant in the Java programming language, sometimes referred to as a type code, that identifies the generic SQL type BIGINT.

Usage

From source file:net.sourceforge.msscodefactory.cfensyntax.v2_2.CFEnSyntaxMySql.CFEnSyntaxMySqlEnWordTable.java

public void deleteEnWordByUNameIdx(CFEnSyntaxAuthorization Authorization, Long argScopeId, String argName) {
    final String S_ProcName = "deleteEnWordByUNameIdx";
    ResultSet resultSet = null;//w  w  w  . jav  a2 s .  co m
    try {
        Connection cnx = schema.getCnx();
        String sql = "call " + schema.getLowerDbSchemaName() + ".sp_delete_enword_by_unameidx( ?, ?, ?, ?, ?"
                + ", " + "?" + ", " + "?" + " )";
        if (stmtDeleteByUNameIdx == null) {
            stmtDeleteByUNameIdx = cnx.prepareStatement(sql);
        }
        int argIdx = 1;
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtDeleteByUNameIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecUserId().toString());
        stmtDeleteByUNameIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecSessionId().toString());
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecTenantId());
        if (argScopeId != null) {
            stmtDeleteByUNameIdx.setLong(argIdx++, argScopeId.longValue());
        } else {
            stmtDeleteByUNameIdx.setNull(argIdx++, java.sql.Types.BIGINT);
        }
        stmtDeleteByUNameIdx.setString(argIdx++, argName);
        stmtDeleteByUNameIdx.executeUpdate();
    } catch (SQLException e) {
        throw CFLib.getDefaultExceptionFactory().newDbException(getClass(), S_ProcName, e);
    } finally {
        if (resultSet != null) {
            try {
                resultSet.close();
            } catch (SQLException e) {
            }
            resultSet = null;
        }
    }
}

From source file:net.sourceforge.msscodefactory.cfacc.v2_0.CFAccDb2LUW.CFAccDb2LUWAccountTable.java

public void updateAccount(CFAccAuthorization Authorization, CFAccAccountBuff Buff) {
    final String S_ProcName = "updateAccount";
    if ("ACCT".equals(Buff.getClassCode())
            && (!schema.isTenantUser(Authorization, Buff.getRequiredTenantId(), "UpdateAccount"))) {
        throw CFLib.getDefaultExceptionFactory().newRuntimeException(getClass(), S_ProcName,
                "Permission denied -- User not part of TSecGroup UpdateAccount");
    }/* www.  j  ava2  s.  c  o m*/
    ResultSet resultSet = null;
    try {
        long TenantId = Buff.getRequiredTenantId();
        long Id = Buff.getRequiredId();
        String AccountCode = Buff.getRequiredAccountCode();
        String Description = Buff.getRequiredDescription();
        short CurrencyId = Buff.getRequiredCurrencyId();
        BigDecimal Balance = Buff.getRequiredBalance();
        Long RollupTenantId = Buff.getOptionalRollupTenantId();
        Long RollupAccountId = Buff.getOptionalRollupAccountId();
        int Revision = Buff.getRequiredRevision();
        Connection cnx = schema.getCnx();
        final String sql = "CALL sp_update_acct( ?, ?, ?, ?, ?, ?" + ", " + "?" + ", " + "?" + ", " + "?" + ", "
                + "?" + ", " + "?" + ", " + "?" + ", " + "?" + ", " + "?" + ", " + "?" + " )";
        if (stmtUpdateByPKey == null) {
            stmtUpdateByPKey = cnx.prepareStatement(sql);
        }
        int argIdx = 1;
        stmtUpdateByPKey.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtUpdateByPKey.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecUserId().toString());
        stmtUpdateByPKey.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecSessionId().toString());
        stmtUpdateByPKey.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtUpdateByPKey.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecTenantId());
        stmtUpdateByPKey.setString(argIdx++, "ACCT");
        stmtUpdateByPKey.setLong(argIdx++, TenantId);
        stmtUpdateByPKey.setLong(argIdx++, Id);
        stmtUpdateByPKey.setString(argIdx++, AccountCode);
        stmtUpdateByPKey.setString(argIdx++, Description);
        stmtUpdateByPKey.setShort(argIdx++, CurrencyId);
        stmtUpdateByPKey.setBigDecimal(argIdx++, Balance);
        if (RollupTenantId != null) {
            stmtUpdateByPKey.setLong(argIdx++, RollupTenantId.longValue());
        } else {
            stmtUpdateByPKey.setNull(argIdx++, java.sql.Types.BIGINT);
        }
        if (RollupAccountId != null) {
            stmtUpdateByPKey.setLong(argIdx++, RollupAccountId.longValue());
        } else {
            stmtUpdateByPKey.setNull(argIdx++, java.sql.Types.BIGINT);
        }
        stmtUpdateByPKey.setInt(argIdx++, Revision);
        resultSet = stmtUpdateByPKey.executeQuery();
        if (resultSet.next()) {
            CFAccAccountBuff updatedBuff = unpackAccountResultSetToBuff(resultSet);
            if (resultSet.next()) {
                resultSet.last();
                throw CFLib.getDefaultExceptionFactory().newRuntimeException(getClass(), S_ProcName,
                        "Did not expect multi-record response, " + resultSet.getRow() + " rows selected");
            }
            Buff.setRequiredAccountCode(updatedBuff.getRequiredAccountCode());
            Buff.setRequiredDescription(updatedBuff.getRequiredDescription());
            Buff.setRequiredCurrencyId(updatedBuff.getRequiredCurrencyId());
            Buff.setRequiredBalance(updatedBuff.getRequiredBalance());
            Buff.setOptionalRollupTenantId(updatedBuff.getOptionalRollupTenantId());
            Buff.setOptionalRollupAccountId(updatedBuff.getOptionalRollupAccountId());
            Buff.setRequiredRevision(updatedBuff.getRequiredRevision());
        } else {
            throw CFLib.getDefaultExceptionFactory().newRuntimeException(getClass(), S_ProcName,
                    "Expected a single-record response, " + resultSet.getRow() + " rows selected");
        }
    } catch (SQLException e) {
        throw CFLib.getDefaultExceptionFactory().newDbException(getClass(), S_ProcName, e);
    } finally {
        if (resultSet != null) {
            try {
                resultSet.close();
            } catch (SQLException e) {
            }
            resultSet = null;
        }
    }
}

From source file:net.sourceforge.msscodefactory.cfacc.v2_0.CFAccDb2LUW.CFAccDb2LUWAccountConfigTable.java

public CFAccAccountConfigBuff[] readBuffByEmpCtcLstIdx(CFAccAuthorization Authorization,
        Long EmpContactListTenantId, Long EmpContactListId) {
    final String S_ProcName = "readBuffByEmpCtcLstIdx";
    ResultSet resultSet = null;/*from ww w. ja v a2 s  .  co  m*/
    try {
        Connection cnx = schema.getCnx();
        final String sql = "CALL sp_read_acct_cfg_by_empctclstidx( ?, ?, ?, ?, ?" + ", " + "?" + ", " + "?"
                + " )";
        if (stmtReadBuffByEmpCtcLstIdx == null) {
            stmtReadBuffByEmpCtcLstIdx = cnx.prepareStatement(sql);
        }
        int argIdx = 1;
        stmtReadBuffByEmpCtcLstIdx.setLong(argIdx++,
                (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtReadBuffByEmpCtcLstIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecUserId().toString());
        stmtReadBuffByEmpCtcLstIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecSessionId().toString());
        stmtReadBuffByEmpCtcLstIdx.setLong(argIdx++,
                (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtReadBuffByEmpCtcLstIdx.setLong(argIdx++,
                (Authorization == null) ? 0 : Authorization.getSecTenantId());
        if (EmpContactListTenantId != null) {
            stmtReadBuffByEmpCtcLstIdx.setLong(argIdx++, EmpContactListTenantId.longValue());
        } else {
            stmtReadBuffByEmpCtcLstIdx.setNull(argIdx++, java.sql.Types.BIGINT);
        }
        if (EmpContactListId != null) {
            stmtReadBuffByEmpCtcLstIdx.setLong(argIdx++, EmpContactListId.longValue());
        } else {
            stmtReadBuffByEmpCtcLstIdx.setNull(argIdx++, java.sql.Types.BIGINT);
        }
        resultSet = stmtReadBuffByEmpCtcLstIdx.executeQuery();
        List<CFAccAccountConfigBuff> buffList = new LinkedList<CFAccAccountConfigBuff>();
        while (resultSet.next()) {
            CFAccAccountConfigBuff buff = unpackAccountConfigResultSetToBuff(resultSet);
            buffList.add(buff);
        }
        int idx = 0;
        CFAccAccountConfigBuff[] retBuff = new CFAccAccountConfigBuff[buffList.size()];
        Iterator<CFAccAccountConfigBuff> iter = buffList.iterator();
        while (iter.hasNext()) {
            retBuff[idx++] = iter.next();
        }
        return (retBuff);
    } catch (SQLException e) {
        throw CFLib.getDefaultExceptionFactory().newDbException(getClass(), S_ProcName, e);
    } finally {
        if (resultSet != null) {
            try {
                resultSet.close();
            } catch (SQLException e) {
            }
            resultSet = null;
        }
    }
}

From source file:net.sourceforge.msscodefactory.cfensyntax.v2_2.CFEnSyntaxMySql.CFEnSyntaxMySqlEnTenseTable.java

public void deleteEnTenseByUNameIdx(CFEnSyntaxAuthorization Authorization, Long argScopeId, String argName) {
    final String S_ProcName = "deleteEnTenseByUNameIdx";
    ResultSet resultSet = null;/*from  w  w w . j  a va 2s  .  c  o m*/
    try {
        Connection cnx = schema.getCnx();
        String sql = "call " + schema.getLowerDbSchemaName() + ".sp_delete_entense_by_unameidx( ?, ?, ?, ?, ?"
                + ", " + "?" + ", " + "?" + " )";
        if (stmtDeleteByUNameIdx == null) {
            stmtDeleteByUNameIdx = cnx.prepareStatement(sql);
        }
        int argIdx = 1;
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtDeleteByUNameIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecUserId().toString());
        stmtDeleteByUNameIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecSessionId().toString());
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecTenantId());
        if (argScopeId != null) {
            stmtDeleteByUNameIdx.setLong(argIdx++, argScopeId.longValue());
        } else {
            stmtDeleteByUNameIdx.setNull(argIdx++, java.sql.Types.BIGINT);
        }
        stmtDeleteByUNameIdx.setString(argIdx++, argName);
        stmtDeleteByUNameIdx.executeUpdate();
    } catch (SQLException e) {
        throw CFLib.getDefaultExceptionFactory().newDbException(getClass(), S_ProcName, e);
    } finally {
        if (resultSet != null) {
            try {
                resultSet.close();
            } catch (SQLException e) {
            }
            resultSet = null;
        }
    }
}

From source file:com.flexive.ejb.beans.BriefcaseEngineBean.java

/**
 * {@inheritDoc}//from w ww  .j  a  va 2  s.c om
 */
@Override
@TransactionAttribute(TransactionAttributeType.REQUIRED)
public void updateItemData(long briefcaseId, BriefcaseItemData updateData) throws FxApplicationException {
    if (updateData == null)
        return;
    Briefcase br = load(briefcaseId); // check read permissions
    Connection con = null;
    PreparedStatement stmt = null;
    try {
        con = Database.getDbConnection();
        // check if the item actually exists
        stmt = con.prepareStatement(
                "SELECT COUNT(*) FROM " + TBL_BRIEFCASE_DATA_ITEM + " WHERE briefcase_id=? AND id=? AND pos=?");
        stmt.setLong(1, briefcaseId);
        stmt.setLong(2, updateData.getId());
        stmt.setInt(3, updateData.getPos());
        ResultSet rs = stmt.executeQuery();
        if (rs == null || !rs.next() || rs.getLong(1) != 1)
            throw new FxNotFoundException(LOG, "ex.briefcase.notFound.item", updateData.getId(), br.getName());
        stmt.close();
        stmt = con.prepareStatement("UPDATE " + TBL_BRIEFCASE_DATA_ITEM
        //               1           2           3            4            5           6                    7        8         9
                + " SET intflag1=?, intflag2=?, intflag3=?, longflag1=?, longflag2=?, metadata=? WHERE briefcase_id=? AND id=? AND pos=?");
        stmt.setLong(7, briefcaseId);
        stmt.setLong(8, updateData.getId());
        stmt.setLong(9, updateData.getPos());
        if (updateData.isIntFlagSet(1))
            stmt.setInt(1, updateData.getIntFlag1());
        else
            stmt.setNull(1, Types.INTEGER);
        if (updateData.isIntFlagSet(2))
            stmt.setInt(2, updateData.getIntFlag2());
        else
            stmt.setNull(2, Types.INTEGER);
        if (updateData.isIntFlagSet(3))
            stmt.setInt(3, updateData.getIntFlag3());
        else
            stmt.setNull(3, Types.INTEGER);
        if (updateData.isLongFlagSet(1))
            stmt.setLong(4, updateData.getLongFlag1());
        else
            stmt.setNull(4, Types.BIGINT);
        if (updateData.isLongFlagSet(2))
            stmt.setLong(5, updateData.getLongFlag2());
        else
            stmt.setNull(5, Types.BIGINT);
        stmt.setString(6, updateData.getMetaData());
        stmt.executeUpdate();
    } catch (Exception e) {
        EJBUtils.rollback(ctx);
        throw new FxUpdateException(LOG, e, "ex.briefcase.updateItemData", br.getName(), updateData.getId(),
                e.getMessage());
    } finally {
        Database.closeObjects(BriefcaseEngineBean.class, con, stmt);
    }
}

From source file:net.sourceforge.msscodefactory.cfensyntax.v2_2.CFEnSyntaxMySql.CFEnSyntaxMySqlEnObjectTable.java

public void deleteEnObjectByUNameIdx(CFEnSyntaxAuthorization Authorization, Long argScopeId, String argName) {
    final String S_ProcName = "deleteEnObjectByUNameIdx";
    ResultSet resultSet = null;//ww  w. j  av a2  s .co  m
    try {
        Connection cnx = schema.getCnx();
        String sql = "call " + schema.getLowerDbSchemaName() + ".sp_delete_enobj_by_unameidx( ?, ?, ?, ?, ?"
                + ", " + "?" + ", " + "?" + " )";
        if (stmtDeleteByUNameIdx == null) {
            stmtDeleteByUNameIdx = cnx.prepareStatement(sql);
        }
        int argIdx = 1;
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtDeleteByUNameIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecUserId().toString());
        stmtDeleteByUNameIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecSessionId().toString());
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecTenantId());
        if (argScopeId != null) {
            stmtDeleteByUNameIdx.setLong(argIdx++, argScopeId.longValue());
        } else {
            stmtDeleteByUNameIdx.setNull(argIdx++, java.sql.Types.BIGINT);
        }
        stmtDeleteByUNameIdx.setString(argIdx++, argName);
        stmtDeleteByUNameIdx.executeUpdate();
    } catch (SQLException e) {
        throw CFLib.getDefaultExceptionFactory().newDbException(getClass(), S_ProcName, e);
    } finally {
        if (resultSet != null) {
            try {
                resultSet.close();
            } catch (SQLException e) {
            }
            resultSet = null;
        }
    }
}

From source file:net.sourceforge.msscodefactory.cfensyntax.v2_2.CFEnSyntaxMySql.CFEnSyntaxMySqlEnClauseTable.java

public void deleteEnClauseByUNameIdx(CFEnSyntaxAuthorization Authorization, Long argScopeId, String argName) {
    final String S_ProcName = "deleteEnClauseByUNameIdx";
    ResultSet resultSet = null;/*from   ww w. jav a  2  s .  c o  m*/
    try {
        Connection cnx = schema.getCnx();
        String sql = "call " + schema.getLowerDbSchemaName() + ".sp_delete_enclause_by_unameidx( ?, ?, ?, ?, ?"
                + ", " + "?" + ", " + "?" + " )";
        if (stmtDeleteByUNameIdx == null) {
            stmtDeleteByUNameIdx = cnx.prepareStatement(sql);
        }
        int argIdx = 1;
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtDeleteByUNameIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecUserId().toString());
        stmtDeleteByUNameIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecSessionId().toString());
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecTenantId());
        if (argScopeId != null) {
            stmtDeleteByUNameIdx.setLong(argIdx++, argScopeId.longValue());
        } else {
            stmtDeleteByUNameIdx.setNull(argIdx++, java.sql.Types.BIGINT);
        }
        stmtDeleteByUNameIdx.setString(argIdx++, argName);
        stmtDeleteByUNameIdx.executeUpdate();
    } catch (SQLException e) {
        throw CFLib.getDefaultExceptionFactory().newDbException(getClass(), S_ProcName, e);
    } finally {
        if (resultSet != null) {
            try {
                resultSet.close();
            } catch (SQLException e) {
            }
            resultSet = null;
        }
    }
}

From source file:net.sourceforge.msscodefactory.cfensyntax.v2_2.CFEnSyntaxMySql.CFEnSyntaxMySqlEnPhraseTable.java

public void deleteEnPhraseByUNameIdx(CFEnSyntaxAuthorization Authorization, Long argScopeId, String argName) {
    final String S_ProcName = "deleteEnPhraseByUNameIdx";
    ResultSet resultSet = null;/*from   w ww  .j  a  v  a 2 s  .  c  o  m*/
    try {
        Connection cnx = schema.getCnx();
        String sql = "call " + schema.getLowerDbSchemaName() + ".sp_delete_enphrase_by_unameidx( ?, ?, ?, ?, ?"
                + ", " + "?" + ", " + "?" + " )";
        if (stmtDeleteByUNameIdx == null) {
            stmtDeleteByUNameIdx = cnx.prepareStatement(sql);
        }
        int argIdx = 1;
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtDeleteByUNameIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecUserId().toString());
        stmtDeleteByUNameIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecSessionId().toString());
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecTenantId());
        if (argScopeId != null) {
            stmtDeleteByUNameIdx.setLong(argIdx++, argScopeId.longValue());
        } else {
            stmtDeleteByUNameIdx.setNull(argIdx++, java.sql.Types.BIGINT);
        }
        stmtDeleteByUNameIdx.setString(argIdx++, argName);
        stmtDeleteByUNameIdx.executeUpdate();
    } catch (SQLException e) {
        throw CFLib.getDefaultExceptionFactory().newDbException(getClass(), S_ProcName, e);
    } finally {
        if (resultSet != null) {
            try {
                resultSet.close();
            } catch (SQLException e) {
            }
            resultSet = null;
        }
    }
}

From source file:net.sourceforge.msscodefactory.cfensyntax.v2_2.CFEnSyntaxMySql.CFEnSyntaxMySqlEnSubjectTable.java

public void deleteEnSubjectByUNameIdx(CFEnSyntaxAuthorization Authorization, Long argScopeId, String argName) {
    final String S_ProcName = "deleteEnSubjectByUNameIdx";
    ResultSet resultSet = null;// w w w.j av  a2  s . co m
    try {
        Connection cnx = schema.getCnx();
        String sql = "call " + schema.getLowerDbSchemaName() + ".sp_delete_ensubj_by_unameidx( ?, ?, ?, ?, ?"
                + ", " + "?" + ", " + "?" + " )";
        if (stmtDeleteByUNameIdx == null) {
            stmtDeleteByUNameIdx = cnx.prepareStatement(sql);
        }
        int argIdx = 1;
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtDeleteByUNameIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecUserId().toString());
        stmtDeleteByUNameIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecSessionId().toString());
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtDeleteByUNameIdx.setLong(argIdx++, (Authorization == null) ? 0 : Authorization.getSecTenantId());
        if (argScopeId != null) {
            stmtDeleteByUNameIdx.setLong(argIdx++, argScopeId.longValue());
        } else {
            stmtDeleteByUNameIdx.setNull(argIdx++, java.sql.Types.BIGINT);
        }
        stmtDeleteByUNameIdx.setString(argIdx++, argName);
        stmtDeleteByUNameIdx.executeUpdate();
    } catch (SQLException e) {
        throw CFLib.getDefaultExceptionFactory().newDbException(getClass(), S_ProcName, e);
    } finally {
        if (resultSet != null) {
            try {
                resultSet.close();
            } catch (SQLException e) {
            }
            resultSet = null;
        }
    }
}

From source file:net.sourceforge.msscodefactory.cfacc.v2_0.CFAccPgSql.CFAccPgSqlAccountConfigTable.java

public CFAccAccountConfigBuff[] readBuffByEmpCtcLstIdx(CFAccAuthorization Authorization,
        Long EmpContactListTenantId, Long EmpContactListId) {
    final String S_ProcName = "readBuffByEmpCtcLstIdx";
    ResultSet resultSet = null;//from ww  w  .j  a v a 2s.c  o m
    try {
        Connection cnx = schema.getCnx();
        String sql = "SELECT * FROM " + schema.getLowerSchemaDbName()
                + ".sp_read_acct_cfg_by_empctclstidx( ?, ?, ?, ?, ?" + ", " + "?" + ", " + "?" + " )";
        if (stmtReadBuffByEmpCtcLstIdx == null) {
            stmtReadBuffByEmpCtcLstIdx = cnx.prepareStatement(sql);
        }
        int argIdx = 1;
        stmtReadBuffByEmpCtcLstIdx.setLong(argIdx++,
                (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtReadBuffByEmpCtcLstIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecUserId().toString());
        stmtReadBuffByEmpCtcLstIdx.setString(argIdx++,
                (Authorization == null) ? "" : Authorization.getSecSessionId().toString());
        stmtReadBuffByEmpCtcLstIdx.setLong(argIdx++,
                (Authorization == null) ? 0 : Authorization.getSecClusterId());
        stmtReadBuffByEmpCtcLstIdx.setLong(argIdx++,
                (Authorization == null) ? 0 : Authorization.getSecTenantId());
        if (EmpContactListTenantId != null) {
            stmtReadBuffByEmpCtcLstIdx.setLong(argIdx++, EmpContactListTenantId.longValue());
        } else {
            stmtReadBuffByEmpCtcLstIdx.setNull(argIdx++, java.sql.Types.BIGINT);
        }
        if (EmpContactListId != null) {
            stmtReadBuffByEmpCtcLstIdx.setLong(argIdx++, EmpContactListId.longValue());
        } else {
            stmtReadBuffByEmpCtcLstIdx.setNull(argIdx++, java.sql.Types.BIGINT);
        }
        resultSet = stmtReadBuffByEmpCtcLstIdx.executeQuery();
        List<CFAccAccountConfigBuff> buffList = new LinkedList<CFAccAccountConfigBuff>();
        while (resultSet.next()) {
            CFAccAccountConfigBuff buff = unpackAccountConfigResultSetToBuff(resultSet);
            buffList.add(buff);
        }
        int idx = 0;
        CFAccAccountConfigBuff[] retBuff = new CFAccAccountConfigBuff[buffList.size()];
        Iterator<CFAccAccountConfigBuff> iter = buffList.iterator();
        while (iter.hasNext()) {
            retBuff[idx++] = iter.next();
        }
        return (retBuff);
    } catch (SQLException e) {
        throw CFLib.getDefaultExceptionFactory().newDbException(getClass(), S_ProcName, e);
    } finally {
        if (resultSet != null) {
            try {
                resultSet.close();
            } catch (SQLException e) {
            }
            resultSet = null;
        }
    }
}