Commit 979ed313 authored by ppatro's avatar ppatro

site code missing

git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@177041 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 57c5a493
...@@ -1947,11 +1947,15 @@ public class SorderWizardEJB extends ValidatorEJB implements SorderWizardEJBLoca ...@@ -1947,11 +1947,15 @@ public class SorderWizardEJB extends ValidatorEJB implements SorderWizardEJBLoca
//Added by Kaustubh on 10-11-2017 to get Total Quantity attributes values from stock [start] //Added by Kaustubh on 10-11-2017 to get Total Quantity attributes values from stock [start]
sql = "select sum (quantity- (case when ALLOC_QTY is null then 0 else ALLOC_QTY end)" + /*sql = "select sum (quantity- (case when ALLOC_QTY is null then 0 else ALLOC_QTY end)" +
"- (case when HOLD_QTY is null then 0 else HOLD_QTY end)) as in_stock from STOCK s,item i" "- (case when HOLD_QTY is null then 0 else HOLD_QTY end)) as in_stock from STOCK s,item i"
+ " where s.item_code=i.ITEM_CODE and i.product_code= ? "; + " where s.item_code=i.ITEM_CODE and i.product_code= ? ";*/
sql = "select sum (quantity- (case when ALLOC_QTY is null then 0 else ALLOC_QTY end)" +
"- (case when HOLD_QTY is null then 0 else HOLD_QTY end)) as in_stock from STOCK s,item i"
+ " where s.item_code=i.ITEM_CODE and i.product_code= ? and s.site_code =? ";
pstmt = conn.prepareStatement(sql); pstmt = conn.prepareStatement(sql);
pstmt.setString(1, itemParent); pstmt.setString(1, itemParent);
pstmt.setString(2, siteCode);
rs = pstmt.executeQuery(); rs = pstmt.executeQuery();
...@@ -2198,12 +2202,18 @@ public class SorderWizardEJB extends ValidatorEJB implements SorderWizardEJBLoca ...@@ -2198,12 +2202,18 @@ public class SorderWizardEJB extends ValidatorEJB implements SorderWizardEJBLoca
//changes by kaustubh on 27 nov 2017 Start //changes by kaustubh on 27 nov 2017 Start
sql = "select sum (quantity- (case when ALLOC_QTY is null then 0 else ALLOC_QTY end)" + /* sql = "select sum (quantity- (case when ALLOC_QTY is null then 0 else ALLOC_QTY end)" +
"- (case when HOLD_QTY is null then 0 else HOLD_QTY end)) as in_stock from STOCK s,item i" "- (case when HOLD_QTY is null then 0 else HOLD_QTY end)) as in_stock from STOCK s,item i"
+ " where s.item_code= ? and i.product_code= ? "; + " where s.item_code= ? and i.product_code= ? ";*/
sql = "select sum (quantity- (case when ALLOC_QTY is null then 0 else ALLOC_QTY end)" +
"- (case when HOLD_QTY is null then 0 else HOLD_QTY end)) as in_stock from STOCK s,item i"
+ " where s.item_code= ? and i.product_code= ? and s.site_code =?";
pstmt = conn.prepareStatement(sql); pstmt = conn.prepareStatement(sql);
pstmt.setString(1, itmCode); pstmt.setString(1, itmCode);
pstmt.setString(2, itemParent); pstmt.setString(2, itemParent);
pstmt.setString(3, siteCode);
rs = pstmt.executeQuery(); rs = pstmt.executeQuery();
while (rs.next()) while (rs.next())
......
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