Commit 7c8347fa authored by rtiwari's avatar rtiwari

CHANGE ORDER BY EXP. IN PROCESS


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@95009 ce508802-f39f-4f6c-b175-0d175dae99d5
parent f3f8c54d
...@@ -1644,11 +1644,13 @@ public class StockAllocationPrc extends ProcessEJB implements StockAllocationPrc ...@@ -1644,11 +1644,13 @@ public class StockAllocationPrc extends ProcessEJB implements StockAllocationPrc
{ {
isActives = true; isActives = true;
orderByStkStr = " AND LOCATION.INV_STAT IN(?,?,?,?,?) "; orderByStkStr = " AND LOCATION.INV_STAT IN(?,?,?,?,?) ";
orderByStkStr = orderByStkStr +" ORDER BY CASE WHEN STOCK.EXP_DATE IS NULL THEN STOCK.CREA_DATE ELSE STOCK.EXP_DATE END,INVSTAT.ALLOC_PREF, STOCK.LOC_CODE "; // ADDED ON 30/APR/14 BY RITESH
} }
else else
{ {
isActives = false; isActives = false;
orderByStkStr = " AND LOCATION.INV_STAT IN(?,?,?,?) "; orderByStkStr = " AND LOCATION.INV_STAT IN(?,?,?,?) ";
orderByStkStr = orderByStkStr +" ORDER BY CASE WHEN STOCK.EXP_DATE IS NULL THEN STOCK.CREA_DATE ELSE STOCK.EXP_DATE END,INVSTAT.ALLOC_PREF_CASE, STOCK.LOC_CODE "; // ADDED ON 30/APR/14 BY RITESH
} }
} }
...@@ -1682,8 +1684,10 @@ public class StockAllocationPrc extends ProcessEJB implements StockAllocationPrc ...@@ -1682,8 +1684,10 @@ public class StockAllocationPrc extends ProcessEJB implements StockAllocationPrc
{ {
getDataSql=getDataSql+orderByStkStr; getDataSql=getDataSql+orderByStkStr;
} }
else // CHANGE ON 30/APR/14 BY RITESH
{
getDataSql=getDataSql+" ORDER BY CASE WHEN STOCK.EXP_DATE IS NULL THEN STOCK.CREA_DATE ELSE STOCK.EXP_DATE END,INVSTAT.ALLOC_PREF, STOCK.LOC_CODE "; getDataSql=getDataSql+" ORDER BY CASE WHEN STOCK.EXP_DATE IS NULL THEN STOCK.CREA_DATE ELSE STOCK.EXP_DATE END,INVSTAT.ALLOC_PREF, STOCK.LOC_CODE ";
}
pstmtStock = conn.prepareStatement(getDataSql); pstmtStock = conn.prepareStatement(getDataSql);
pstmtStock.setString(1,itemCode); pstmtStock.setString(1,itemCode);
pstmtStock.setString(2,siteCodeShip); pstmtStock.setString(2,siteCodeShip);
......
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