Commit 9e3b99c2 authored by ssarkar's avatar ssarkar

changed by sumit on 18/12/12 closing statement


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@92377 ce508802-f39f-4f6c-b175-0d175dae99d5
parent c85c18ad
......@@ -1091,6 +1091,13 @@ public class NearExpiryPrc extends ProcessEJB implements NearExpiryPrcLocal,Near
{
System.out.println( updCnt + " rows updated successfully FOR "+tranIdGenerate );
}
//Changed by sumit on 17/12/12 closing statement
if(pRelHdr != null)
{
pRelHdr.close();
pRelHdr = null;
}
//Changed by sumit on 17/12/12 closing statement
//making details
HashMap dataMap = new HashMap();
......@@ -1111,6 +1118,13 @@ public class NearExpiryPrc extends ProcessEJB implements NearExpiryPrcLocal,Near
}
batchUpd = pRelDet.executeBatch();
System.out.println("nos of row updated "+batchUpd);
//Changed by sumit on 17/12/12 closing statement
if(pRelDet != null)
{
pRelDet.close();
pRelDet = null;
}
//Changed by sumit on 17/12/12 closing statement
// if(batchUpd.length >0)
// conn.commit();
InvHoldRelConf invHoldRelConf = new InvHoldRelConf();
......@@ -1125,6 +1139,27 @@ public class NearExpiryPrc extends ProcessEJB implements NearExpiryPrcLocal,Near
e.printStackTrace();
throw new ITMException(e);
}
finally
{
try
{
if(pRelHdr != null)
{
pRelHdr.close();
pRelHdr = null;
}
if(pRelDet != null)
{
pRelDet.close();
pRelDet = null;
}
}
catch(Exception e)
{
throw new ITMException(e);
}
}
return errString;
}
private String generateTranId( String windowName, String siteCode, String tranDateStr, Connection conn )throws ITMException
......
......@@ -1424,6 +1424,13 @@ private String checkNull(String input)
{
System.out.println( updCnt + " rows updated successfully FOR "+tranIdGenerate );
}
//Changed by sumit on 17/12/12 closing statement
if(pRelHdr != null)
{
pRelHdr.close();
pRelHdr = null;
}
//Changed by sumit on 17/12/12 closing statement
//making details
HashMap dataMap = new HashMap();
......@@ -1444,6 +1451,13 @@ private String checkNull(String input)
}
batchUpd = pRelDet.executeBatch();
System.out.println("nos of row updated "+batchUpd);
//Changed by sumit on 17/12/12 closing statement
if(pRelDet != null)
{
pRelDet.close();
pRelDet = null;
}
//Changed by sumit on 17/12/12 closing statement
// if(batchUpd.length >0)
// conn.commit();
InvHoldRelConf invHoldRelConf = new InvHoldRelConf();
......@@ -1459,6 +1473,26 @@ private String checkNull(String input)
e.printStackTrace();
throw new ITMException(e);
}
finally
{
try
{
if(pRelHdr != null)
{
pRelHdr.close();
pRelHdr = null;
}
if(pRelDet != null)
{
pRelDet.close();
pRelDet = null;
}
}
catch(Exception e)
{
throw new ITMException(e);
}
}
return errString;
}
......
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