X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=includes%2Fsystypes.inc;h=974adfdbb0ed51f27272ab4f6e5d6ec168c0a075;hb=175a48c5bd73abe16e77fa2cb48ba522f00d1501;hp=1c91abc2e33e6f6aa5dc0e35347b99fe0b397930;hpb=df3ebb4251529abb480179600417fe7164951fe2;p=fa-stable.git diff --git a/includes/systypes.inc b/includes/systypes.inc index 1c91abc2..974adfdb 100644 --- a/includes/systypes.inc +++ b/includes/systypes.inc @@ -26,7 +26,7 @@ function get_next_trans_no ($trans_type){ $sql = "SELECT MAX(`$st[2]`) FROM $st[0]"; if ($st[1] != null) - $sql .= " WHERE `$st[1]`=$trans_type"; + $sql .= " WHERE `$st[1]`=".db_escape($trans_type); $result = db_query($sql,"The next transaction number for $trans_type could not be retrieved"); $myrow = db_fetch_row($result);