on 12-18-2008 10:25 AM
Morning all,
I am using Crosstab in my report, the problem I am getting is that when there is no data against the column, crosstab does not show that number.
For example
Days - 1 2 3 5
Jobs - 1 2 3 6
Here in the above example the Day 4 did not have any data, i.e. 0 number of jobs went through, the crosstab is missing the 4th day.
How can I make crosstab to show all the number of days regardless of number of jobs?
Any ideas
Regards
Jehanzeb
Hi Jehanzeb,
Please try the following:
Goto File-> Report Options-> Check the two options
1.Convert Database NULL values to Default
2.Convert Other NULL values to Default
Click OK and refresh the report.
Hope this helps you!
Regards,
Anindita
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Any ideas how to do a manual crosstab?
I think that is the only way to get around this issue.
Regardless of number of jobs, the total number of days from 0 to 10+ should show up. I think that is what Crosstab cannot do.
and I don't know how to create a manual crosstab column wise.
Any ideas?
Regards
Jehanzeb
Edited by: Jehanzeb Navid on Dec 18, 2008 5:43 PM
I just ran the report without any data i.e. any record except Number of days. When I ran the report using the date range and Account number, it showed me number of days
Days = 0 - 1 - 2 - 3 - 4 - 5 - 9 - 10+
So this means that the number of days are getting filtered by the entry I put into the parameters and that reflect into the crosstab.
I tried using a manual Mock Crosstab but no luck it still doesn't show the missing number of days.Additionally it shows the data by Row and I want it by column.
Unless I fake the days by using a text object it won't display all days, however you can't really fake days in crosstab can you?
I think I am stuck with this because the when there is no date entry against a record how can it be shown?
Regards
Hi J,
Go in Cross Tab Expert--Customize Style tab- and uncheck Suppress Empty Rows and Suppress Empty Columns
Thanks,
Sastry
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for your quick response Sastry but my issues it that the number of jobs are shown against number of days. If there are no jobs in that particular day then it should show 0 and show the day.
For example
Days - 1 - 2 - 3 - 4 - 6 - 7 - 8 - 9 - 10+
Jobs - 1 - 3 - 4 - 6 - 7 - 9 - 0 - 1 - 11
The above example is what I want however when Crosstab is ran the report shows
Days - 1 - 2 - 3 - 4 - 6 - 7 - 9 - 10+
Jobs - 1 - 3 - 4 - 6 - 7 - 9 - 1 - 11
It just simply takes off 8th day which has no records.
I am using the following formula on the Column of the crosstab (In other words this is my Number of days formula).
WhileReadingRecords;
Local DateVar Start := {order_header.date_entered}; // Starting Date
Local DateVar End := {order_header.act_despatch}; // Ending Date
Local NumberVar Weeks; // Number of weeks
Local NumberVar Days; // Number of days
Local Numbervar Hol:=0; //Number of holidays
DateVar Array Holidays; // Bank holidays dates array
Weeks:=(Truncate(End - dayofweek(End) + 1 - (Start - dayofweek(Start) + 1))/7)*5;
Days:=DayOfWeek(end) - Dayofweek(Start) + 1
+ (if dayofweek(start) = 1 then -1 else 0) //adjust for starting on sunday:
+(if dayofweek(end) = 7 then -1 else 0); //adjust for ending on a saturday:
//Check for bank holidays
Local NumberVar i;
For i := 1 to Count (Holidays)
do (if DayOfWeek (Holidays<i>) in 2 to 6 and
Holidays<i> in Start to End then Hol:=Hol+1 );
Weeks + Days - Hol;
If (Weeks + Days - Hol) < 11 then
1
else
2;
If (Weeks + Days - Hol) <= 10 then
totext((Weeks+Days-Hol)-1,0,'')
else
"10+"
Then the above formula is specified in the following order
Show = Actual Day
0 = 1Day
1 = 2Day
2 = 3Day
3 = 4Day
4 = 5Day
5 = 6Day
6 = 7Day
7 = 8Day
8 = 9Day
9 = 10Day
10+ = 11Day
Does this make any sense?
Regards
Jehanzeb
Hi J,
I don't thing you have some problem with your No.of Days formula. The issue is like if you have 0 (zero) in Noof Jobs then it is not showing the column.i.e not showing the value and not showing the number of days.
Try to write the following in disply string in Number of jobs
If currentfieldvalue > 0 Then
totext(currentfieldvalue)
else "0"
This will keep zero 0 in noof jobs to disply.
Thanks,
Sastry
User | Count |
---|---|
82 | |
10 | |
10 | |
9 | |
6 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.