Commit dced14d5 authored by manohar's avatar manohar

In case of issue or allocate issue sock existence checking added in the begining


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@92638 ce508802-f39f-4f6c-b175-0d175dae99d5
parent c49233cf
...@@ -105,6 +105,40 @@ public class StockUpdate ...@@ -105,6 +105,40 @@ public class StockUpdate
creaDt = new Timestamp(System.currentTimeMillis()) ; creaDt = new Timestamp(System.currentTimeMillis()) ;
System.out.println("creaDt Initialized Current date:::- ["+creaDt+"]"); System.out.println("creaDt Initialized Current date:::- ["+creaDt+"]");
} }
// 05/02/13 manoharan check for stock if issue
if (this.tranType.equalsIgnoreCase("I") || this.tranType.equalsIgnoreCase("ID") )
{
sql =" select count(1) from stock where item_code = ? "
+" and site_code = ? "
+" and loc_code = ? "
+" and lot_no = ? "
+" and lot_sl = ? ";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1,this.itemCode);
pstmt.setString(2,this.siteCode);
pstmt.setString(3,this.locationCode);
pstmt.setString(4,this.lotNo);
pstmt.setString(5,this.lotSl);
rs = pstmt.executeQuery();
if(rs.next())
{
count = rs.getInt(1);
}
pstmt.close();
pstmt = null;
rs.close();
rs = null;
if (count == 0)
{
errString = "VTSTOCK1";
errString = itmDBAccessEJB.getErrorString("",errString,"","",conn);
return errString;
}
}
// end 05/02/13 manoharan
/*if gs_run_mode <> 'B' then//Batch load to be checked, currently the current Date /*if gs_run_mode <> 'B' then//Batch load to be checked, currently the current Date
s_updatestock.currdate = ldt_today // and create date is taken as current timestamp s_updatestock.currdate = ldt_today // and create date is taken as current timestamp
......
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