Commit 15aa8c35 authored by mchauhan's avatar mchauhan

Sql syntax correction

git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@216181 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 943e41de
...@@ -125,7 +125,7 @@ public class PostOrdCreditChk ...@@ -125,7 +125,7 @@ public class PostOrdCreditChk
/// new product order type should not be consider. /// new product order type should not be consider.
/// amish 01-10-03 /// amish 01-10-03
//added by nandkumar gakari on 10/12/19--------------start----------------------- //added by nandkumar gakari on 10/12/19--------------start-----------------------
lsSql = "select order_type from sorder where sale_order = ?" ; lsSql = "select order_type from sorder where sale_order = ?";
pstmt = conn.prepareStatement(lsSql); pstmt = conn.prepareStatement(lsSql);
pstmt.setString(1,asSorder); pstmt.setString(1,asSorder);
rs = pstmt.executeQuery(); rs = pstmt.executeQuery();
...@@ -160,7 +160,7 @@ public class PostOrdCreditChk ...@@ -160,7 +160,7 @@ public class PostOrdCreditChk
} }
ordTypeNewPrd = ordTypeNewPrd.trim(); ordTypeNewPrd = ordTypeNewPrd.trim();
//Added By PriyankaC on 03June2019 [Start] //Added By PriyankaC on 03June2019 [Start]
lsSql = "select cust_name from customer where cust_code = ?" ; lsSql = "select cust_name from customer where cust_code = ?";
pstmt = conn.prepareStatement(lsSql); pstmt = conn.prepareStatement(lsSql);
pstmt.setString(1,asCustCodeBil); pstmt.setString(1,asCustCodeBil);
rs = pstmt.executeQuery(); rs = pstmt.executeQuery();
...@@ -173,7 +173,7 @@ public class PostOrdCreditChk ...@@ -173,7 +173,7 @@ public class PostOrdCreditChk
pstmt.close(); pstmt.close();
pstmt = null; pstmt = null;
lsSql = "select cust_name from customer where cust_code = ?" ; lsSql = "select cust_name from customer where cust_code = ?";
pstmt = conn.prepareStatement(lsSql); pstmt = conn.prepareStatement(lsSql);
pstmt.setString(1,asCustCodeSoldTo); pstmt.setString(1,asCustCodeSoldTo);
rs = pstmt.executeQuery(); rs = pstmt.executeQuery();
...@@ -258,8 +258,8 @@ public class PostOrdCreditChk ...@@ -258,8 +258,8 @@ public class PostOrdCreditChk
// and length(rtrim(item_ser__crpolicy)) > 0 // and length(rtrim(item_ser__crpolicy)) > 0
// and oth_series = 'G'; // and oth_series = 'G';
//commented above and changed to below for length replacement on manoharanji's instruction ** kiran 28/06/05 //commented above and changed to below for length replacement on manoharanji's instruction ** kiran 28/06/05
lsSql = "select item_ser , item_ser__crpolicy , oth_series " lsSql = " select item_ser,item_ser__crpolicy,oth_series from itemser where item_ser = ? " ;
+ " from itemser where item_ser = ?" ;
pstmt = conn.prepareStatement(lsSql); pstmt = conn.prepareStatement(lsSql);
pstmt.setString(1,asItemSer); pstmt.setString(1,asItemSer);
...@@ -3000,7 +3000,7 @@ public class PostOrdCreditChk ...@@ -3000,7 +3000,7 @@ public class PostOrdCreditChk
lsSql = "select sum(tot_amt - adj_amt - dispute_amt ) as adv_amt " lsSql = "select sum(tot_amt - adj_amt - dispute_amt ) as adv_amt "
+ " FROM receivables " + " FROM receivables "
+ " WHERE tran_ser = 'R-ADV' and ref_no in (select tran_id from receipt " + " WHERE tran_ser = 'R-ADV' and ref_no in (select tran_id from receipt "
+ " where sale_order = ? "; + " where sale_order = ?)"; //Mukesh chauhan Added missing end bracket on 05/02/2020
pstmt = conn.prepareStatement(lsSql); pstmt = conn.prepareStatement(lsSql);
pstmt.setString(1,asSorder); pstmt.setString(1,asSorder);
...@@ -3697,6 +3697,7 @@ public class PostOrdCreditChk ...@@ -3697,6 +3697,7 @@ public class PostOrdCreditChk
// " into :lsContactCode , :lcCustCrlmt " + // " into :lsContactCode , :lcCustCrlmt " +
" from customer " + " from customer " +
" where cust_code = ? "; " where cust_code = ? ";
pstmt = conn.prepareStatement(sql); pstmt = conn.prepareStatement(sql);
pstmt.setString(1,asCustCodeBil); pstmt.setString(1,asCustCodeBil);
rs = pstmt.executeQuery(); rs = pstmt.executeQuery();
......
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