registered a statement as closed which wasn't known to be open. This could happen if you close a statement twice.

解决方案 »

  1.   

    <select id="findTest" parameterClass="java.util.HashMap"
    resultClass="java.lang.Integer" remapResults="true">
    <![CDATA[
    SELECT count(*)
    FROM SUP_TEMP_AUTHORIZATION_TEST 
    WHERE
    BUSINESS_ID = #BUSINESS_ID#
    AND USERID = #USERID#
    ]]>
    </select>
      

  2.   

     public List searchVersionDocInfo(List<SwInfoFormBean> aSwList, String aNls,HttpServletRequest aRequest)
            throws Exception
        {
            IPoApplyWs poApplyWs = new IPoApplyWsProxy();
            JSONObject inputJson = new JSONObject();
            if (!aSwList.isEmpty())
            {
                inputJson.put("NLS_LANG", aNls);
                //传入版本id、文档id
                inputJson.put("VERSION_ID", "\'" + aSwList.get(0).getVersion()
                        + "\'");
                inputJson.put("PRODUCT_ID", "\'" + aSwList.get(0).getPp_product()
                        + "\'");
                UserInfoBean user = null;
                user = getUserInfo(aRequest);
                
                //用户所在的组
                String userGroupId[] = user.getGroups();
                StringBuilder userGroupIdStr = new StringBuilder();
                for (int i = 0; i < userGroupId.length; i++)
                {
                    userGroupIdStr.append(userGroupId[i] + ",");
                }
                String userGruop = userGroupIdStr.toString();
                userGruop = userGruop.substring(0, userGruop.length() - 1);
                
                inputJson.put("USERGROUPIDSTR", userGruop);
                //用户
                inputJson.put("USEID", user.getUid());
                
            }
            String aListVersionDocStr = poApplyWs.
                         getRelatedVersionDocBySWId(inputJson.toString());
            
            String aListProductManualSoftStr = poApplyWs.
            getRelatedProductManualSoftBySWId(inputJson.toString());
            
            List listOne = JsonUtil.jsonArrayToList(new JSONArray(aListVersionDocStr));        
            List listTwo = JsonUtil.jsonArrayToList(new JSONArray(aListProductManualSoftStr));        
            for(Object obj : listOne){
                listTwo.add(obj);            
            }   
            
            
            
            if (null != aListVersionDocStr && !"".equals(aListVersionDocStr))
            {
              //  return JsonUtil.jsonArrayToList(new JSONArray(aListStr));
                return listTwo;
            }
            return new ArrayList<SwInfoFormBean>();
        }