List transactions by dimension

I’m working on a project for a client where they want a customized report that lists ledger transactions sorted by ledger account, profit center (dimension), cost center (dimension), date and then voucher number. I’ve set up the dimensions, dimension focuses and hierarchies. Some of the built in reports come very close to doing this (Ledger Transaction List, Dimension Statement).

The Microsoft Partner they were working with modified the Ledger Transaction List (copied it first), it shows most of the required information yet some of the opening balances* are shown as 0, and the ending balance is much different than the sum of the transactions in that group. The problem occurs on just a few cost centers. So, maybe some ledger transactions or vouchers are correctly associated with the relevant cost center?

Any assistance on getting this to work would be greatly appreciated.

*The method they used is called openingBalance - the code just says ‘return openingBalance’. I’ve looked at the LedgerTransReportEngine Class,
AmountMST insertOpeningBalance method - would that be better?