Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
error in ReverseGRN.php
01-31-2012, 05:40 AM,
#1
error in ReverseGRN.php
Phil,

There is a SQL statement in ReverseGRN that fails to execute.
$SQL = "SELECT grns.podetailitem,
grns.grnbatch,
grns.itemcode,
grns.itemdescription,
grns.deliverydate,
purchorderdetails.glcode,
purchorderdetails.assetid,
grns.qtyrecd,
grns.quantityinv,
purchorderdetails.stdcostunit,
purchorders.intostocklocation,
purchorders.orderno
FROM grns INNER JOIN purchorderdetails
ON grns.podetailitem=purchorderdetails.podetailitem
INNER JOIN purchorders
ON purchorderdetails.orderno = purchorders.orderno
WHERE AND grnno='" . $_GET['GRNNo'] . "'";

Note the last line
WHERE AND grnno='" . $_GET['GRNNo'] . "'";
Should there be something before the 'AND'?
Reply
01-31-2012, 06:19 AM,
#2
RE: error in ReverseGRN.php
Thanks, Tim
I'll remove it and update the SVN
Reply
01-31-2012, 06:54 AM,
#3
RE: error in ReverseGRN.php
I changed a lot of SQL from using the old style JOIN syntax i.e just a comma separated list of table names to the ANSI style, some of the extra conditions to specify the join were no longer necessary - this is just a typo...
Nice spot ..

Thanks Vitaly Smile
Phil Daintree
webERP Admin
Logic Works Ltd
http://www.logicworks.co.nz
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)