Focal Point
[SOLVED] Showing the field, even when no data

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/5117018776

August 13, 2015, 11:31 AM
Pops
[SOLVED] Showing the field, even when no data
I want to do a report that shows all the WORKCENTERS and how many hours were charged during the timeframe, by Job#. The report works fine, with one exception...

If there are no hours, that Workcenter doesn't show up.

An idea of what the report looks like:

__________WC#1 WC#2 WC#4
JOB#.............8.0 __ 0.0 __ 0.0
JOB#.............0.0 __ 5.0 __ 1.0
JOB#.............1.0 __ 1.0 __ 1.0

Only three fields, and I can get 0.0 if that JOB has no hours, but look above, there is no WC#3 showing because no hours were charged that day.

SUM: Charged Hours
BY: JOB#
ACROSS: WORKCENTER

Two data sources, JOB ROUTER and TIMESHEET

My Join is Left Outer

This message has been edited. Last edited by: Tamra,


Release: WebFOCUS 8
Windows
HTML, PDF, EXCEL
August 13, 2015, 06:21 PM
Waz
Have you looked into using ACROSS {field} COLUMNS {val} AND {val} AND {val} ....


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

August 14, 2015, 10:55 AM
Pops
....
TABLE FILE MO_HDR
SUM MIN.J002.TS_LN_MO.TS_DT NOPRINT
MAX.J002.TS_LN_MO.TS_DT NOPRINT
J003.TS_LN_MO.CHG_HRS
BY MO_HDR.MO_HDR.MO_ID
ACROSS Define_2 AS 'Location'
ACROSS Define_1 AS 'WorkCenter'

So you are saying, I would substitute the line above with
ACROSS {field} COLUMNS {val} AND {val} AND {val} ....

like this:
ACROSS (Workcenter) COLUMNS (BEND SHOP) AND (WELD SHOP) AND (PANEL SHOP)


Release: WebFOCUS 8
Windows
HTML, PDF, EXCEL
August 14, 2015, 11:30 AM
Pops
Once again, the Great and Powerful WAZ to the rescue of the feeble minded non-programming wanna be.....

Thanks!!! If I ever get back to Sydney, I owe you a cold Fosters


Release: WebFOCUS 8
Windows
HTML, PDF, EXCEL
August 17, 2015, 03:44 PM
Pops
The only thing I would add....

If you save this using EDIT WITH TEXT and open it again with INFO ASSIST, you lose the text line you created:

ACROSS (Workcenter) COLUMNS (BEND SHOP) AND (WELD SHOP) AND (PANEL SHOP)


So make all the INFO ASSIST corrections then add the text line.


Release: WebFOCUS 8
Windows
HTML, PDF, EXCEL
August 17, 2015, 06:45 PM
Waz
Hi Pops,

You don't need the brackets, I only used the {} to indicate changeable values.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

May 06, 2016, 03:41 PM
Mitchell
Hi,

I understand using ACROSS {field} COLUMNS {val} AND {val} AND {val} code when you know which columns you want to see.

However, is there a way to do this when you are running a report for the last 7 days and want to see the dates displayed for days that have not data. For example, on a shipped revenue report, I want to see the weekend dates shown even though there are not sales for that day.

thank you...


WebFOCUS 8
Windows, All Outputs
May 07, 2016, 07:57 AM
eric.woerle
Do you have a date table? You can't show a record that doesn't exist. I've always joined a calendar table to my request when I want to handle things like that. This way you will always have a record where the value is 0 for that day.


Eric Woerle
8.1.05M Gen 913- Reporting Server Unix
8.1.05 Client Unix
Oracle 11.2.0.2