/**
   * @param mdwSubscriber
   * @param newSubscriber
   * @author Eric
   * @comment Inserts a subscriber into MecDocSub
   */
  private void generateAndInsertMecDocSub(MecMdw mdwSubscriber, Subscriber newSubscriber) {
    // TODO: check employer sponsored codes
    if (MecConstants.EMPLOYER_SPONSORED_PLANS.contains(mdwSubscriber.getRep_policy_ogn_cd())) {
      newSubscriber.setEmployer_name(mdwSubscriber.getRep_ein_emp_name());
      newSubscriber.setEmployer_name2("");
      newSubscriber.setEmployer_ein(mdwSubscriber.getRep_ein());
      newSubscriber.setEmp_addr1(mdwSubscriber.getRep_ein_addr1());
      newSubscriber.setEmp_addr2(mdwSubscriber.getRep_ein_addr2());
      newSubscriber.setEmp_city(mdwSubscriber.getRep_ein_city());
      newSubscriber.setEmp_state(mdwSubscriber.getRep_ein_state());
      newSubscriber.setEmp_province(mdwSubscriber.getRep_ein_province());
      newSubscriber.setEmp_zip(mdwSubscriber.getRep_ein_zip());
      newSubscriber.setEmp_zip_4(mdwSubscriber.getRep_ein_zip_4());
      newSubscriber.setEmp_country_cd(mdwSubscriber.getRep_ein_country_Cd());
      newSubscriber.setEmp_country(mdwSubscriber.getRep_ein_country_name());
      newSubscriber.setEmp_foreign_zip(mdwSubscriber.getRep_ein_foreign_zip_code());
    }

    Date dob =
        mecUtils.parseDate(
            mdwSubscriber.getSbscrb_dob(), mecProperty.getProperty(MecConstants.MDW_DOB_FORMAT));
    newSubscriber.setDob(dob);
    newSubscriber.setPolicy_origin_cd(mdwSubscriber.getRep_policy_ogn_cd());
    newSubscriber.setShop_idn_num(mdwSubscriber.getRep_shop_market_id());
    newSubscriber.setSsn(mdwSubscriber.getRep_ssn());
    newSubscriber.setSubs_type_cd(mdwSubscriber.getSbscrb_typ_cd());
    newSubscriber.setFirst_nm(mdwSubscriber.getSbscrb_frst_nm());
    newSubscriber.setMiddle_nm(mdwSubscriber.getSbscrb_mdl_nm());
    newSubscriber.setLast_nm(mdwSubscriber.getSbscrb_lst_nm());
    newSubscriber.setSuffix_nm(mdwSubscriber.getSbscrb_sfx());
    newSubscriber.setAddr1(mdwSubscriber.getSbscrb_lne_1());
    newSubscriber.setAddr2(mdwSubscriber.getSbscrb_lne_2());
    newSubscriber.setCity(mdwSubscriber.getSbscrb_cty_nm());
    newSubscriber.setState(mdwSubscriber.getSbscrb_st_cd());
    newSubscriber.setSub_province(mdwSubscriber.getSbscrb_prvnc());
    newSubscriber.setZip(mdwSubscriber.getSbscrb_zip_cd());
    newSubscriber.setMailzip4(mdwSubscriber.getSbscrb_zip_pls_4());
    newSubscriber.setSub_country_cd(mdwSubscriber.getSbscrb_cntry_cd());
    newSubscriber.setCountry(mdwSubscriber.getSbscrb_cntry_name());
    newSubscriber.setSub_foreign_cd(mdwSubscriber.getSbscrb_frn_pstl_cd());
    newSubscriber.setRgn_cd(mdwSubscriber.getRgn_cd());
    newSubscriber.setMrn(mdwSubscriber.getSbscrb_mrn());
    newSubscriber.setMrn_pfx(mdwSubscriber.getSbscrb_mrn_pfx());
    newSubscriber.setFk_mdw_id(mdwSubscriber.getMdw_id());
    newSubscriber.setIrs_trans_type(MecConstants.ORIGINAL_DOC);
    newSubscriber.setStmt_type(MecConstants.ORIGINAL_DOC);
    newSubscriber.setCreated_by(mecProperty.getProperty(MecConstants.CREATED_BY));
    newSubscriber.setTax_year(mdwSubscriber.getTax_year());
    newSubscriber.setFk_issuer_id(mdwSubscriber.getRep_kaiser_issuer_id());
    // NON-COV Subscribers do not need coverage months
    if (mecProperty.getProperty(MecConstants.SUBSCRIBER).equals(newSubscriber.getSubs_type_cd())) {
      updateMecDocMonths(mdwSubscriber, newSubscriber);
    }
    try {
      // TODO: load region table by memory
      // logger.error("88888=   "+mecRegions.getRegion(1));
      // newRecord.setFk_region_id(regionMapper.getRegionIdByMdwCode(mdwRecord.getRgn_cd()));
      newSubscriber.setFk_region_id(mecRegions.getRegionIdByMdwCode(mdwSubscriber.getRgn_cd()));
    } catch (BindingException e) {
      logger.error("Error: " + e.getMessage(), e);
      throw e;
    }
    mecDocMapper.insertSubscriberRecord(newSubscriber);
  }