Commit 3db5e586 authored by msingh's avatar msingh

Changed by Manish on 01/04/16 for maximum cursor issue for DDUK .


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@101072 ce508802-f39f-4f6c-b175-0d175dae99d5
parent ebad5d95
...@@ -830,6 +830,18 @@ public class AcctBalTransPrc extends ProcessEJB implements AcctBalTransPrcLocal, ...@@ -830,6 +830,18 @@ public class AcctBalTransPrc extends ProcessEJB implements AcctBalTransPrcLocal,
compName = rs.getString("COMP_NAME"); compName = rs.getString("COMP_NAME");
} }
System.out.println("serviceCode = "+serviceCode+" compName "+compName); System.out.println("serviceCode = "+serviceCode+" compName "+compName);
// Changed by Manish on 01/04/16 for max cursor issue [start]
if (pstmt != null)
{
pstmt.close();
pstmt=null;
}
if (rs !=null)
{
rs.close();
rs=null;
}
// Changed by Manish on 01/04/16 for max cursor issue [end]
sql = "SELECT SERVICE_URI FROM SYSTEM_EVENT_SERVICES WHERE SERVICE_CODE = ? "; sql = "SELECT SERVICE_URI FROM SYSTEM_EVENT_SERVICES WHERE SERVICE_CODE = ? ";
pstmt = conn.prepareStatement(sql); pstmt = conn.prepareStatement(sql);
pstmt.setString(1,serviceCode); pstmt.setString(1,serviceCode);
...@@ -839,6 +851,18 @@ public class AcctBalTransPrc extends ProcessEJB implements AcctBalTransPrcLocal, ...@@ -839,6 +851,18 @@ public class AcctBalTransPrc extends ProcessEJB implements AcctBalTransPrcLocal,
serviceURI = rs.getString("SERVICE_URI"); serviceURI = rs.getString("SERVICE_URI");
} }
System.out.println("serviceURI = "+serviceURI+" compName = "+compName); System.out.println("serviceURI = "+serviceURI+" compName = "+compName);
// Changed by Manish on 01/04/16 for max cursor issue [start]
if (pstmt != null)
{
pstmt.close();
pstmt=null;
}
if (rs !=null)
{
rs.close();
rs=null;
}
// Changed by Manish on 01/04/16 for max cursor issue [end]
Service service = new Service(); Service service = new Service();
Call call = (Call)service.createCall(); Call call = (Call)service.createCall();
call.setTargetEndpointAddress(new java.net.URL(serviceURI)); call.setTargetEndpointAddress(new java.net.URL(serviceURI));
...@@ -880,6 +904,11 @@ public class AcctBalTransPrc extends ProcessEJB implements AcctBalTransPrcLocal, ...@@ -880,6 +904,11 @@ public class AcctBalTransPrc extends ProcessEJB implements AcctBalTransPrcLocal,
pstmt.close(); pstmt.close();
pstmt = null; pstmt = null;
} }
if (rs !=null)
{
rs.close();
rs=null;
}
/*if( conn != null ){ /*if( conn != null ){
conn.close(); conn.close();
conn = null; conn = null;
......
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -9783,7 +9783,11 @@ public class FinCommon ...@@ -9783,7 +9783,11 @@ public class FinCommon
break; break;
} }
while (true); while (true);
if(pstmt != null)
{
pstmt.close();
pstmt = null;
}
} }
catch ( SQLException sqlE) catch ( SQLException sqlE)
{ {
......
...@@ -730,6 +730,18 @@ public class JvYearEndPrc extends ProcessEJB implements JvYearEndPrcLocal,JvYear ...@@ -730,6 +730,18 @@ public class JvYearEndPrc extends ProcessEJB implements JvYearEndPrcLocal,JvYear
compName = rs.getString("COMP_NAME"); compName = rs.getString("COMP_NAME");
} }
System.out.println("serviceCode = "+serviceCode+" compName "+compName); System.out.println("serviceCode = "+serviceCode+" compName "+compName);
// Changed by Manish on 01/04/16 for max cursor issue [start]
if (pstmt != null)
{
pstmt.close();
pstmt=null;
}
if (rs !=null)
{
rs.close();
rs=null;
}
// Changed by Manish on 01/04/16 for max cursor issue [end]
sql = "SELECT SERVICE_URI FROM SYSTEM_EVENT_SERVICES WHERE SERVICE_CODE = ? "; sql = "SELECT SERVICE_URI FROM SYSTEM_EVENT_SERVICES WHERE SERVICE_CODE = ? ";
pstmt = conn.prepareStatement(sql); pstmt = conn.prepareStatement(sql);
pstmt.setString(1,serviceCode); pstmt.setString(1,serviceCode);
...@@ -739,6 +751,18 @@ public class JvYearEndPrc extends ProcessEJB implements JvYearEndPrcLocal,JvYear ...@@ -739,6 +751,18 @@ public class JvYearEndPrc extends ProcessEJB implements JvYearEndPrcLocal,JvYear
serviceURI = rs.getString("SERVICE_URI"); serviceURI = rs.getString("SERVICE_URI");
} }
System.out.println("serviceURI = "+serviceURI+" compName = "+compName); System.out.println("serviceURI = "+serviceURI+" compName = "+compName);
// Changed by Manish on 01/04/16 for max cursor issue [start]
if (pstmt != null)
{
pstmt.close();
pstmt=null;
}
if (rs !=null)
{
rs.close();
rs=null;
}
// Changed by Manish on 01/04/16 for max cursor issue [end]
Service service = new Service(); Service service = new Service();
Call call = (Call)service.createCall(); Call call = (Call)service.createCall();
call.setTargetEndpointAddress(new java.net.URL(serviceURI)); call.setTargetEndpointAddress(new java.net.URL(serviceURI));
...@@ -780,6 +804,11 @@ public class JvYearEndPrc extends ProcessEJB implements JvYearEndPrcLocal,JvYear ...@@ -780,6 +804,11 @@ public class JvYearEndPrc extends ProcessEJB implements JvYearEndPrcLocal,JvYear
pstmt.close(); pstmt.close();
pstmt = null; pstmt = null;
} }
if (rs !=null)
{
rs.close();
rs=null;
}
/*if( conn != null ){ /*if( conn != null ){
conn.close(); conn.close();
conn = null; conn = null;
......
...@@ -77,8 +77,8 @@ public class MilestonePayGen ...@@ -77,8 +77,8 @@ public class MilestonePayGen
String taskCodePrv="",relAgainst="",result=""; String taskCodePrv="",relAgainst="",result="";
String wfStatus ="",tranIdMilestn="",detailsResult="",tranIdCurr=""; String wfStatus ="",tranIdMilestn="",detailsResult="",tranIdCurr="";
String lineNoOrd=""; String lineNoOrd="";
String retString="",taskCodeDescr=""; String retString="";
String sql = "",errString="",xtraParams="",siteCode="",sql2=""; String sql = "",errString="",xtraParams="",siteCode="";
boolean isSavedMilstn=true; boolean isSavedMilstn=true;
double odtAmt=0.0,totAmt=0.0,calRelAmt=0.0,taxAmt=0.0; double odtAmt=0.0,totAmt=0.0,calRelAmt=0.0,taxAmt=0.0;
double relAmtPass=0.0; double relAmtPass=0.0;
...@@ -87,8 +87,8 @@ public class MilestonePayGen ...@@ -87,8 +87,8 @@ public class MilestonePayGen
int relAfterInt= 0; int relAfterInt= 0;
Date dueDateUpd=null; Date dueDateUpd=null;
Timestamp tsDueDate = null,confDate = null; Timestamp tsDueDate = null,confDate = null;
PreparedStatement pstmt = null,pstmt2=null; PreparedStatement pstmt = null;
ResultSet rs = null,rs2=null; ResultSet rs = null;
GenericUtility genericUtility = GenericUtility.getInstance(); GenericUtility genericUtility = GenericUtility.getInstance();
Connection conn = null; Connection conn = null;
ConnDriver connDriver = new ConnDriver(); ConnDriver connDriver = new ConnDriver();
...@@ -286,21 +286,6 @@ public class MilestonePayGen ...@@ -286,21 +286,6 @@ public class MilestonePayGen
dueDateUpd = utilmethod.RelativeDate(tsDueDate, totdelayDays); dueDateUpd = utilmethod.RelativeDate(tsDueDate, totdelayDays);
System.out.println("dueDateUpd :" + dueDateUpd);*/ System.out.println("dueDateUpd :" + dueDateUpd);*/
sql2 = " select descr from gencodes where fld_name='TASK_CODE' and mod_name='W_PORDER' and fld_value= ? ";
pstmt2 = conn.prepareStatement(sql2);
pstmt2.setString(1, taskCode);
rs2 = pstmt2.executeQuery();
if (rs2.next())
{
taskCodeDescr= checkNull(rs2.getString("descr"));
}
rs2.close();
rs2 = null;
pstmt2.close();
pstmt2 = null;
System.out.println(">>>taskCodeDescr:"+ taskCodeDescr);
StringBuffer xmlBuff = new StringBuffer(); StringBuffer xmlBuff = new StringBuffer();
...@@ -339,7 +324,6 @@ public class MilestonePayGen ...@@ -339,7 +324,6 @@ public class MilestonePayGen
xmlBuff.append("<tax_chap><![CDATA[" + taxChap + "]]></tax_chap>"); xmlBuff.append("<tax_chap><![CDATA[" + taxChap + "]]></tax_chap>");
xmlBuff.append("<tax_env><![CDATA[" + taxEnv + "]]></tax_env>"); xmlBuff.append("<tax_env><![CDATA[" + taxEnv + "]]></tax_env>");
xmlBuff.append("<task_code><![CDATA[" + taskCode + "]]></task_code>"); xmlBuff.append("<task_code><![CDATA[" + taskCode + "]]></task_code>");
xmlBuff.append( "<task_descr><![CDATA["+taskCodeDescr+"]]></task_descr>");// Code added by Sagar on 27/11/15
xmlBuff.append("<amount><![CDATA[" + calRelAmt + "]]></amount>"); xmlBuff.append("<amount><![CDATA[" + calRelAmt + "]]></amount>");
xmlBuff.append("<due_date><![CDATA[" + dueDate + "]]></due_date>"); xmlBuff.append("<due_date><![CDATA[" + dueDate + "]]></due_date>");
//xmlBuff.append("<due_date><![CDATA[" + sdf1.format(dueDateUpd).toString() + "]]></due_date>"); //xmlBuff.append("<due_date><![CDATA[" + sdf1.format(dueDateUpd).toString() + "]]></due_date>");
...@@ -362,9 +346,6 @@ public class MilestonePayGen ...@@ -362,9 +346,6 @@ public class MilestonePayGen
xmlBuff.append("<chg_date><![CDATA[" + tranDate + "]]></chg_date>"); xmlBuff.append("<chg_date><![CDATA[" + tranDate + "]]></chg_date>");
xmlBuff.append("<chg_term><![CDATA[" + chgTerm + "]]></chg_term>"); xmlBuff.append("<chg_term><![CDATA[" + chgTerm + "]]></chg_term>");
xmlBuff.append("<date_format><![CDATA["+e12GenericUtility.getApplDateFormat()+"]]></date_format>"); xmlBuff.append("<date_format><![CDATA["+e12GenericUtility.getApplDateFormat()+"]]></date_format>");
xmlBuff.append( "<ord_amt><![CDATA["+odtAmt+"]]></ord_amt>"); // Code added by Sagar on 27/11/15 Start.
xmlBuff.append( "<tax_amt><![CDATA["+taxAmt+"]]></tax_amt>");
xmlBuff.append( "<tot_amt><![CDATA["+totAmt+"]]></tot_amt>"); // Code added by Sagar on 27/11/15 End.
xmlBuff.append("</Detail1>"); xmlBuff.append("</Detail1>");
xmlBuff.append("</Header0>"); xmlBuff.append("</Header0>");
...@@ -935,10 +916,10 @@ public class MilestonePayGen ...@@ -935,10 +916,10 @@ public class MilestonePayGen
System.out.println("processDate1:"+processDate); System.out.println("processDate1:"+processDate);
System.out.println("datediff :"+datediff); System.out.println("datediff :"+datediff);
/* /*
select * from TARODEV.pord_dlv_term where purc_order='718PNF0299' select * from TARODEV.pord_dlv_term where purc_order='718PNF0299'
and min_day <=14 and max_day>=14 and min_day <=14 and max_day>=14
*/ */
/* sql = "select * from (select min_day,max_day,fin_chg,fchg_type,min_amt,max_amt from pord_dlv_term where " + /* sql = "select * from (select min_day,max_day,fin_chg,fchg_type,min_amt,max_amt from pord_dlv_term where " +
...@@ -1465,7 +1446,7 @@ public class MilestonePayGen ...@@ -1465,7 +1446,7 @@ public class MilestonePayGen
/* /*
private String saveData(String siteCode,String xmlString,String xtraParams, Connection conn) throws ITMException private String saveData(String siteCode,String xmlString,String xtraParams, Connection conn) throws ITMException
{ {
System.out.println("saving data..........."); System.out.println("saving data...........");
...@@ -1550,6 +1531,18 @@ public class MilestonePayGen ...@@ -1550,6 +1531,18 @@ public class MilestonePayGen
compName = rs.getString("COMP_NAME"); compName = rs.getString("COMP_NAME");
} }
System.out.println("serviceCode = "+serviceCode+" compName "+compName); System.out.println("serviceCode = "+serviceCode+" compName "+compName);
// Changed by Manish on 01/04/16 for max cursor issue [start]
if (pstmt != null)
{
pstmt.close();
pstmt=null;
}
if (rs !=null)
{
rs.close();
rs=null;
}
// Changed by Manish on 01/04/16 for max cursor issue [end]
sql = "SELECT SERVICE_URI FROM SYSTEM_EVENT_SERVICES WHERE SERVICE_CODE = ? "; sql = "SELECT SERVICE_URI FROM SYSTEM_EVENT_SERVICES WHERE SERVICE_CODE = ? ";
pstmt = conn.prepareStatement(sql); pstmt = conn.prepareStatement(sql);
pstmt.setString(1,serviceCode); pstmt.setString(1,serviceCode);
...@@ -1559,6 +1552,18 @@ public class MilestonePayGen ...@@ -1559,6 +1552,18 @@ public class MilestonePayGen
serviceURI = rs.getString("SERVICE_URI"); serviceURI = rs.getString("SERVICE_URI");
} }
System.out.println("serviceURI = "+serviceURI+" compName = "+compName); System.out.println("serviceURI = "+serviceURI+" compName = "+compName);
// Changed by Manish on 01/04/16 for max cursor issue [start]
if (pstmt != null)
{
pstmt.close();
pstmt=null;
}
if (rs !=null)
{
rs.close();
rs=null;
}
// Changed by Manish on 01/04/16 for max cursor issue [end]
Service service = new Service(); Service service = new Service();
Call call = (Call)service.createCall(); Call call = (Call)service.createCall();
call.setTargetEndpointAddress(new java.net.URL(serviceURI)); call.setTargetEndpointAddress(new java.net.URL(serviceURI));
...@@ -1601,6 +1606,11 @@ public class MilestonePayGen ...@@ -1601,6 +1606,11 @@ public class MilestonePayGen
pstmt.close(); pstmt.close();
pstmt = null; pstmt = null;
} }
if (rs !=null)
{
rs.close();
rs=null;
}
/*if( conn != null ){ /*if( conn != null ){
conn.close(); conn.close();
conn = null; conn = null;
......
...@@ -75,10 +75,6 @@ public class MiscPayConfSch implements Schedule ...@@ -75,10 +75,6 @@ public class MiscPayConfSch implements Schedule
String strToWrite=""; String strToWrite="";
SimpleDateFormat sdf1 = new SimpleDateFormat(genericUtility.getDBDateFormat()); SimpleDateFormat sdf1 = new SimpleDateFormat(genericUtility.getDBDateFormat());
String currTime = null; String currTime = null;
String epayNoDays="";
int noOfDays=0;
Date fromDate=null;
Timestamp fromDateDB=null;
Calendar calendar = Calendar.getInstance(); Calendar calendar = Calendar.getInstance();
currTime = sdf1.format(new Timestamp(System.currentTimeMillis())).toString(); currTime = sdf1.format(new Timestamp(System.currentTimeMillis())).toString();
currTime = currTime.replaceAll("-",""); currTime = currTime.replaceAll("-","");
...@@ -108,7 +104,6 @@ public class MiscPayConfSch implements Schedule ...@@ -108,7 +104,6 @@ public class MiscPayConfSch implements Schedule
userInfo = new ibase.utility.UserInfoBean( scheduleParamXML ); userInfo = new ibase.utility.UserInfoBean( scheduleParamXML );
loginSiteCode = userInfo.getSiteCode(); loginSiteCode = userInfo.getSiteCode();
java.util.Date today=new java.util.Date(); java.util.Date today=new java.util.Date();
Calendar c = Calendar.getInstance(); Calendar c = Calendar.getInstance();
c.setTime(today); c.setTime(today);
...@@ -126,35 +121,9 @@ public class MiscPayConfSch implements Schedule ...@@ -126,35 +121,9 @@ public class MiscPayConfSch implements Schedule
Timestamp newsysDate = java.sql.Timestamp.valueOf( sdf1.format(currentDate)+" 00:00:00.0"); Timestamp newsysDate = java.sql.Timestamp.valueOf( sdf1.format(currentDate)+" 00:00:00.0");
System.out.println(">>>> newsysDate is:"+newsysDate); System.out.println(">>>> newsysDate is:"+newsysDate);
java.util.Date todayDate=new java.util.Date(); queryString = "SELECT TRAN_ID FROM MISC_PAYMENT WHERE CONFIRMED='N' AND WF_STATUS='S' AND REF_DATE= ? ";
// Code added by Sagar on 25/11/15 Start
FinCommon finCommon=new FinCommon();
UtilMethods utilmethod = new UtilMethods();
epayNoDays = checkNull(finCommon.getFinparams("999999", "EPAY_NO_DAYS", conn));
System.out.println(">>>>epayNoDays:"+epayNoDays);
//Retrive no of days from finparam, If it is not null then minus noofdays from current date and set as from date, Other wise noofdays is null then set current date.
if(epayNoDays!=null && epayNoDays.trim().length() > 0 && !"NULLFOUND".equals(epayNoDays) )
{
noOfDays= Integer.parseInt(epayNoDays);
fromDate = utilmethod.RelativeDate(currentDate, -noOfDays);
System.out.println(">>>fromDate:"+fromDate);
}
else
{
fromDate= currentDate;
}
fromDateDB = java.sql.Timestamp.valueOf(sdf1.format(fromDate)+" 00:00:00.0");
System.out.println(">>>>>fromDateDB:"+fromDateDB);
System.out.println(">>>>>newsysDate:"+newsysDate);
// Code added by Sagar on 25/11/15 End
//queryString = "SELECT TRAN_ID FROM MISC_PAYMENT WHERE CONFIRMED='N' AND WF_STATUS='S' AND REF_DATE= ? "; // Comment added by Sagar on 25/11/15
queryString = "SELECT TRAN_ID FROM MISC_PAYMENT WHERE CONFIRMED='N' AND WF_STATUS='S' AND REF_DATE BETWEEN ? AND ? ";
pstmt = conn.prepareStatement(queryString); pstmt = conn.prepareStatement(queryString);
pstmt.setTimestamp(1, fromDateDB ); pstmt.setTimestamp(1, newsysDate );
pstmt.setTimestamp(2, newsysDate );
rs=pstmt.executeQuery(); rs=pstmt.executeQuery();
while(rs.next()) while(rs.next())
{ {
...@@ -282,6 +251,18 @@ public class MiscPayConfSch implements Schedule ...@@ -282,6 +251,18 @@ public class MiscPayConfSch implements Schedule
compName = rs.getString("COMP_NAME"); compName = rs.getString("COMP_NAME");
} }
System.out.println(">>>Misc Payments serviceCode = "+serviceCode+" compName "+compName); System.out.println(">>>Misc Payments serviceCode = "+serviceCode+" compName "+compName);
// Changed by Manish on 01/04/16 for max cursor issue [start]
if (pstmt != null)
{
pstmt.close();
pstmt=null;
}
if (rs !=null)
{
rs.close();
rs=null;
}
// Changed by Manish on 01/04/16 for max cursor issue [end]
sql = "SELECT SERVICE_URI FROM SYSTEM_EVENT_SERVICES WHERE SERVICE_CODE = ? "; sql = "SELECT SERVICE_URI FROM SYSTEM_EVENT_SERVICES WHERE SERVICE_CODE = ? ";
pstmt = conn.prepareStatement(sql); pstmt = conn.prepareStatement(sql);
pstmt.setString(1,serviceCode); pstmt.setString(1,serviceCode);
...@@ -291,6 +272,18 @@ public class MiscPayConfSch implements Schedule ...@@ -291,6 +272,18 @@ public class MiscPayConfSch implements Schedule
serviceURI = rs.getString("SERVICE_URI"); serviceURI = rs.getString("SERVICE_URI");
} }
System.out.println(">>>Misc Payments serviceURI = "+serviceURI+" compName = "+compName); System.out.println(">>>Misc Payments serviceURI = "+serviceURI+" compName = "+compName);
// Changed by Manish on 01/04/16 for max cursor issue [start]
if (pstmt != null)
{
pstmt.close();
pstmt=null;
}
if (rs !=null)
{
rs.close();
rs=null;
}
// Changed by Manish on 01/04/16 for max cursor issue [end]
Service service = new Service(); Service service = new Service();
Call call = (Call)service.createCall(); Call call = (Call)service.createCall();
call.setTargetEndpointAddress(new java.net.URL(serviceURI)); call.setTargetEndpointAddress(new java.net.URL(serviceURI));
...@@ -330,6 +323,11 @@ public class MiscPayConfSch implements Schedule ...@@ -330,6 +323,11 @@ public class MiscPayConfSch implements Schedule
pstmt.close(); pstmt.close();
pstmt = null; pstmt = null;
} }
if (rs !=null)
{
rs.close();
rs=null;
}
/*if( conn != null ){ /*if( conn != null ){
conn.close(); conn.close();
conn = null; conn = null;
...@@ -375,13 +373,5 @@ public class MiscPayConfSch implements Schedule ...@@ -375,13 +373,5 @@ public class MiscPayConfSch implements Schedule
} }
catch(Exception exWm){exWm.printStackTrace();} catch(Exception exWm){exWm.printStackTrace();}
} }
private String checkNull(String input)
{
if (input == null)
{
input = "";
}
return input.trim();
}
} }
...@@ -1603,6 +1603,18 @@ public class ReceivablesTransPrc extends ProcessEJB implements ReceivablesTransP ...@@ -1603,6 +1603,18 @@ public class ReceivablesTransPrc extends ProcessEJB implements ReceivablesTransP
compName = rs.getString("COMP_NAME"); compName = rs.getString("COMP_NAME");
} }
System.out.println("serviceCode = "+serviceCode+" compName "+compName); System.out.println("serviceCode = "+serviceCode+" compName "+compName);
// Changed by Manish on 01/04/16 for max cursor issue [start]
if (pstmt != null)
{
pstmt.close();
pstmt=null;
}
if (rs !=null)
{
rs.close();
rs=null;
}
// Changed by Manish on 01/04/16 for max cursor issue [end]
sql = "SELECT SERVICE_URI FROM SYSTEM_EVENT_SERVICES WHERE SERVICE_CODE = ? "; sql = "SELECT SERVICE_URI FROM SYSTEM_EVENT_SERVICES WHERE SERVICE_CODE = ? ";
pstmt = conn.prepareStatement(sql); pstmt = conn.prepareStatement(sql);
pstmt.setString(1,serviceCode); pstmt.setString(1,serviceCode);
...@@ -1612,6 +1624,18 @@ public class ReceivablesTransPrc extends ProcessEJB implements ReceivablesTransP ...@@ -1612,6 +1624,18 @@ public class ReceivablesTransPrc extends ProcessEJB implements ReceivablesTransP
serviceURI = rs.getString("SERVICE_URI"); serviceURI = rs.getString("SERVICE_URI");
} }
System.out.println("serviceURI = "+serviceURI+" compName = "+compName); System.out.println("serviceURI = "+serviceURI+" compName = "+compName);
// Changed by Manish on 01/04/16 for max cursor issue [start]
if (pstmt != null)
{
pstmt.close();
pstmt=null;
}
if (rs !=null)
{
rs.close();
rs=null;
}
// Changed by Manish on 01/04/16 for max cursor issue [end]
Service service = new Service(); Service service = new Service();
Call call = (Call)service.createCall(); Call call = (Call)service.createCall();
call.setTargetEndpointAddress(new java.net.URL(serviceURI)); call.setTargetEndpointAddress(new java.net.URL(serviceURI));
......
...@@ -362,6 +362,11 @@ public class VoucherConfScheduler implements Schedule ...@@ -362,6 +362,11 @@ public class VoucherConfScheduler implements Schedule
pstmt.close(); pstmt.close();
pstmt = null; pstmt = null;
} }
if (rs != null )
{
rs.close();
rs = null;
}
/*if( conn != null ){ /*if( conn != null ){
conn.close(); conn.close();
conn = null; conn = null;
......
...@@ -1080,6 +1080,18 @@ public String confirmMiscVoucher(String businessObj, String tranIdFr,String xtra ...@@ -1080,6 +1080,18 @@ public String confirmMiscVoucher(String businessObj, String tranIdFr,String xtra
} }
compName=compName==null ? "" :compName.trim(); compName=compName==null ? "" :compName.trim();
System.out.println("serviceCode = ["+serviceCode+"] compName ["+compName+"]"); System.out.println("serviceCode = ["+serviceCode+"] compName ["+compName+"]");
// Changed by Manish on 01/04/16 for max cursor issue [start]
if (pstmt != null)
{
pstmt.close();
pstmt=null;
}
if (rs !=null)
{
rs.close();
rs=null;
}
// Changed by Manish on 01/04/16 for max cursor issue [end]
sql = "SELECT SERVICE_URI FROM SYSTEM_EVENT_SERVICES WHERE SERVICE_CODE = ? "; sql = "SELECT SERVICE_URI FROM SYSTEM_EVENT_SERVICES WHERE SERVICE_CODE = ? ";
pstmt = conn.prepareStatement(sql); pstmt = conn.prepareStatement(sql);
pstmt.setString(1,serviceCode); pstmt.setString(1,serviceCode);
...@@ -1090,6 +1102,18 @@ public String confirmMiscVoucher(String businessObj, String tranIdFr,String xtra ...@@ -1090,6 +1102,18 @@ public String confirmMiscVoucher(String businessObj, String tranIdFr,String xtra
} }
serviceURI=serviceURI==null ? "" :serviceURI.trim(); serviceURI=serviceURI==null ? "" :serviceURI.trim();
System.out.println("serviceURI---->>["+serviceURI+"]---> compName = ["+compName+"]"); System.out.println("serviceURI---->>["+serviceURI+"]---> compName = ["+compName+"]");
// Changed by Manish on 01/04/16 for max cursor issue [start]
if (pstmt != null)
{
pstmt.close();
pstmt=null;
}
if (rs !=null)
{
rs.close();
rs=null;
}
// Changed by Manish on 01/04/16 for max cursor issue [end]
Service service = new Service(); Service service = new Service();
Call call = (Call)service.createCall(); Call call = (Call)service.createCall();
call.setTargetEndpointAddress(new java.net.URL(serviceURI)); call.setTargetEndpointAddress(new java.net.URL(serviceURI));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment