Haxtuple1

Solution for bug 24450. Metasql was modified to show credit memos as negative values in both queries, payments to be selected and also selected payments query.