- $sql = "SELECT type, trans_no, ref, trans_date,
- amount, person_id, person_type_id, reconciled, id
- FROM ".TB_PREF."bank_trans
- WHERE ".TB_PREF."bank_trans.bank_act = ".db_escape($bank_account) . "
+ $sql = "SELECT bt.type, trans_no, ref, trans_date,
+ amount, charge, person_id, person_type_id, reconciled, bt.id, c.memo_
+ FROM ".TB_PREF."bank_trans bt
+ LEFT JOIN ".TB_PREF."comments c ON c.type = bt.type AND c.id = bt.trans_no
+ WHERE bank_act = ".db_escape($bank_account) . "