过滤重复记录(因为关联扩展表)

 if (resultSet != null)
        {
          resultSet.setFetchSize(1024);
          UserImpl user = null;
          while (true) { while (true) { if (!(resultSet.next()))
                break label209;
              if ((null == user) || (!(user.getOperID().equals(resultSet.getString(SystemManageConstants.UserTable.operID.name())))))
              {
                break;
              }

              String extName = resultSet.getString(SystemManageConstants.ExtAttributeTable.attrName.name());

              String extValue = resultSet.getString(SystemManageConstants.ExtAttributeTable.attrValue.name());

              if (null != extName)
              {
                user.addExtAttribute(extName, extValue);
              }

            }

            user = new UserImpl(resultSet);
            users.add(user);
          }

        }

      }
      catch (SQLException ex)
      {
      }
      finally
      {
        label209: dataResult.close();
      }

posted @ 2014-01-06 14:52  刺客XIII  阅读(251)  评论(0编辑  收藏  举报