Crosstab

Hi,

Is it possible to represent the data A/B fashion in the Crosstab?? I have two different Columns coming from the database. I want to represent then on the Crosstab side by side (Column A/Column B) is this possible...??
minhajmAsked:
Who is Participating?
 
mlmccConnect With a Mentor Commented:
I don't think you can get the /.  Side by side is controlled through the Crosstab Expert.  On the CUSTOMIZE STYLE tab set the SUmmarized Fields to horizontal.

Are the values actually sums or are they individual fields?
If individual fields you might be able to use a formula for the value
Something like

CStr({A},0,'') & ' / ' & CStr({B},0,'')

mlmcc
0
 
mlmccCommented:
It should be.

Simply add bith fields as the summary fiekds.

mlmcc
0
 
minhajmAuthor Commented:
Hi
Sorry I have not understood this. what are bith fields...?? can you pls provide more details.
0
Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

 
mlmccCommented:
When you create the cross tab you can add row and columns and you also can add the fields for the summary.  If you add both A and B you should get what you want.

mlmcc
0
 
mlmccCommented:
Sorry that should have been BOTH

mlmcc
0
 
minhajmAuthor Commented:
When i add Both fields for summary..in crosstab it shows one below the other...I need it side by side sepearted by "/". Somthing like this (250 / 300) in the same line.
0
 
minhajmAuthor Commented:
Hi,

Formula is working great thanks. Can i also have the Background color for the CStr({B},0,"") in this formula.
0
 
mlmccCommented:
As far as I know the background color will apply to the whole cell.  You can't change it for part of the cell.

mlmcc
0
 
James0628Connect With a Mentor Commented:
If you have two numeric fields in the cross-tab, you can get a "/" in between the numbers by adding it to the format for one of the fields.  Note that it won't actually be in between the two fields.  It will be part of one field.  If you were going to export the report to something like an Excel file, that would probably be a problem, because that one field wouldn't be numeric anymore (eg. instead of 250, the field would be 250/).  If you're not going to export the report, then that's not an issue.

 The basic idea is to pick one of the fields, go to the format, enable the currency symbol and change the symbol to be / instead of $.  For example, go to the format for the left field, tell it to show a currency symbol to the right of the number and change the symbol from $ to /.  Then 250 would show as 250/.  Or go to the format for the right field and have it display the currency symbol, fixed, to the left of the number (so 300 would show as "/  300").

 If you want some spaces before/after the /, instead of just typing the / in the currency symbol box, click on the formula (X+2) button to the right and enter a string with the slash and your spaces.  For example:
"   /"

 If you enter spaces in the currency symbol box, CR will just remove them, but not if you put them in the formula.


 If this allows you to use two fields in the cross-tab, then you can change the bg color on one of them.  Just keep in mind that the / will be part of one of the fields, so if you change the bg color on that field, that will include the part with the /.  With that in mind, if you want to change the bg color on the right field, you may want to add the / to the left field.

 James
0
 
corobvConnect With a Mentor Commented:
Another way to do it is to create a formula called Slash and put " / " in it. Save it and then add it to the summary as a Max or minimum.  Either would work. Place it  in between the two other summaries. Summarized the fields  horizontally as MIMCC suggested above.  Then you should be able to change the color of both or either of the fields, and the  / would remain the default color.
0
 
James0628Commented:
Nice idea.  I just tried it in a cross-tab here and it worked to a degree.  I did not get a "/" in the cells where both numbers were 0 (meaning that there were no records for that cell).  That field just doesn't show up in those cells at all.  Maybe there's a way around that, but I suspect not.  But if that's not a problem for the OP (either because they don't have any cells like that, or because they don't mind not getting a "/" in the "0" cells), then that may be the best solution yet.

 James
0
 
corobvCommented:
You could suppress the zeros also.  You have to format the cell go the number tab, click custom and check mark suppress if zero.  That way the entire field will be blank.  
0
 
James0628Commented:
True.  Of course if there are some cells where one number is 0 and one is not, that might not work so well.  You'd have one number and the "/", but not the other number (0).

 James
0
 
James0628Commented:
I would give some points to corobv as well, for post 24440334.  His idea of adding a "slash" formula to the cross-tab was simple, and worked well in my test, apart from not showing up when both of the numeric summaries were 0, which may not have been an issue for the OP.

 James
0
All Courses

From novice to tech pro — start learning today.