public CFSecurityISOCountryBuff readBuff(
     CFSecurityAuthorization Authorization, CFSecurityISOCountryPKey PKey) {
   final String S_ProcName = "readBuff";
   if (!schema.isTransactionOpen()) {
     throw CFLib.getDefaultExceptionFactory()
         .newUsageException(getClass(), S_ProcName, "Transaction not open");
   }
   ResultSet resultSet = null;
   try {
     Connection cnx = schema.getCnx();
     short Id = PKey.getRequiredId();
     String sql = "{ call sp_read_iso_cntry( ?, ?, ?, ?, ?" + ", " + "?" + " ) }";
     if (stmtReadBuffByPKey == null) {
       stmtReadBuffByPKey = cnx.prepareStatement(sql);
     }
     int argIdx = 1;
     stmtReadBuffByPKey.setLong(
         argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
     stmtReadBuffByPKey.setString(
         argIdx++, (Authorization == null) ? "" : Authorization.getSecUserId().toString());
     stmtReadBuffByPKey.setString(
         argIdx++, (Authorization == null) ? "" : Authorization.getSecSessionId().toString());
     stmtReadBuffByPKey.setLong(
         argIdx++, (Authorization == null) ? 0 : Authorization.getSecClusterId());
     stmtReadBuffByPKey.setLong(
         argIdx++, (Authorization == null) ? 0 : Authorization.getSecTenantId());
     stmtReadBuffByPKey.setShort(argIdx++, Id);
     resultSet = stmtReadBuffByPKey.executeQuery();
     if ((resultSet != null) && resultSet.next()) {
       CFSecurityISOCountryBuff buff = unpackISOCountryResultSetToBuff(resultSet);
       if (resultSet.next()) {
         resultSet.last();
         throw CFLib.getDefaultExceptionFactory()
             .newRuntimeException(
                 getClass(),
                 S_ProcName,
                 "Did not expect multi-record response, " + resultSet.getRow() + " rows selected");
       }
       return (buff);
     } else {
       return (null);
     }
   } catch (SQLException e) {
     throw CFLib.getDefaultExceptionFactory().newDbException(getClass(), S_ProcName, e);
   } finally {
     if (resultSet != null) {
       try {
         resultSet.close();
       } catch (SQLException e) {
       }
       resultSet = null;
     }
   }
 }
 public ICFSecurityISOCountryObj readISOCountry(CFSecurityISOCountryPKey pkey, boolean forceRead) {
   ICFSecurityISOCountryObj obj = null;
   if ((!forceRead) && members.containsKey(pkey)) {
     obj = members.get(pkey);
   } else {
     CFSecurityISOCountryBuff readBuff =
         ((ICFInternetSchema) schema.getBackingStore())
             .getTableISOCountry()
             .readDerivedByIdIdx(schema.getAuthorization(), pkey.getRequiredId());
     if (readBuff != null) {
       obj = schema.getISOCountryTableObj().newInstance();
       obj.setPKey(
           ((ICFInternetSchema) schema.getBackingStore()).getFactoryISOCountry().newPKey());
       obj.setBuff(readBuff);
       obj = (ICFSecurityISOCountryObj) obj.realize();
     } else if (schema.getCacheMisses()) {
       members.put(pkey, null);
     }
   }
   return (obj);
 }
 public void deleteISOCountryByIdIdx(
     CFSecurityAuthorization Authorization, CFSecurityISOCountryPKey argKey) {
   deleteISOCountryByIdIdx(Authorization, argKey.getRequiredId());
 }
 public static String formatISOCountryPKeyAttributes(
     String separator, CFSecurityISOCountryPKey pkey) {
   String retval = CFLibXmlUtil.formatRequiredInt16(null, "Id", pkey.getRequiredId());
   return (retval);
 }