Remove empty lines from financial report

Description

Financial reports are after some time cluttered with lines that are empty (i.e all colums are zero). The lines are probably on the report becase there are values in different periods that isn't shown in the report. This looks unprofessional and makes the reading of the report harder.

Suggested improvement to the report is to add the following to the method FinReport.deleteUnprintedLines()

String sql = "DELETE FROM T_Report WHERE AD_PInstance_ID=" + getAD_PInstance_ID() +
" AND (COL_0 IS NULL OR COL_0=0) " +
" AND (COL_1 IS NULL OR COL_1=0) " +
" AND (COL_2 IS NULL OR COL_2=0) " +
" AND (COL_3 IS NULL OR COL_3=0) " +
" AND (COL_4 IS NULL OR COL_4=0) " +
" AND (COL_5 IS NULL OR COL_5=0) " +
" AND (COL_6 IS NULL OR COL_6=0) " +
" AND (COL_7 IS NULL OR COL_7=0) " +
" AND (COL_8 IS NULL OR COL_8=0) " +
" AND (COL_9 IS NULL OR COL_9=0) " +
" AND (COL_10 IS NULL OR COL_10=0) " +
" AND (COL_11 IS NULL OR COL_11=0) " +
" AND (COL_12 IS NULL OR COL_12=0) " +
" AND (COL_13 IS NULL OR COL_13=0) " +
" AND (COL_14 IS NULL OR COL_14=0) " +
" AND (COL_15 IS NULL OR COL_15=0) " +
" AND (COL_16 IS NULL OR COL_16=0) " +
" AND (COL_17 IS NULL OR COL_17=0) " +
" AND (COL_18 IS NULL OR COL_18=0) " +
" AND (COL_19 IS NULL OR COL_19=0) " +
" AND (COL_20 IS NULL OR COL_20=0) ";
DB.executeUpdate(sql, get_TrxName());

Environment

None

Activity

Show:
Alan Lescano
May 19, 2017, 1:23 PM

hi
Useful for some financial reports, but some of them still need the zeroed/null lines. I created a flag in PA_Report that allows the deletion of those zero lines

Assignee

Unassigned

Reporter

Daniel Tamm

Labels

Tested By

None

Time tracking

20m

Components

Affects versions

Priority

Major
Configure