Page 1 of 1

adding a column to a cross tab report

Posted: Fri Jan 03, 2014 1:10 am
by erikbrandvig
how can I add a column to a cross tab report?

the cross tab portion is calculating correctly, but we need to add a column directly from the sql result to the cross tab.

also, is it possible to have the "line numbers" displayed on the cross tab? {line} did not work... it displayed "1" for the entire report.

Re: adding a column to a cross tab report

Posted: Fri Jan 03, 2014 6:16 am
by HighAley
Hello.
erikbrandvig wrote:the cross tab portion is calculating correctly, but we need to add a column directly from the sql result to the cross tab.
Could you describe this issue more detailed? The cross-tab is rendered
erikbrandvig wrote:also, is it possible to have the "line numbers" displayed on the cross tab? {line} did not work... it displayed "1" for the entire report.
You could get the Column and Row in the Process Cell event:

Code: Select all

e.Cell
e.Column
Thank you.

Re: adding a column to a cross tab report

Posted: Mon Jan 06, 2014 9:46 pm
by erikbrandvig
are you suggesting that "e.Cell" would return the row number?

do you think that I should use a variable to count rows in the "process cell" event? is that available in the properties window of the cross-tab report?

another column in the cross-tab... I want to add another column in the cross-tab. I understand that the cross-tab results are grouped... there is only one value per "grouped value" that I want to add.

Code: Select all

     grouping value   added column   cross-tab columns
1    value 1              string1               1    4
2    value 2              string 2              2    5
3    value 3              string 3              3    6

Re: adding a column to a cross tab report

Posted: Thu Jan 09, 2014 6:51 am
by HighAley
Hello.
erikbrandvig wrote:are you suggesting that "e.Cell" would return the row number?
Sorry, the e.Row will show the Row number.
erikbrandvig wrote:do you think that I should use a variable to count rows in the "process cell" event? is that available in the properties window of the cross-tab report?

another column in the cross-tab... I want to add another column in the cross-tab. I understand that the cross-tab results are grouped... there is only one value per "grouped value" that I want to add.

Code: Select all

     grouping value   added column   cross-tab columns
1    value 1              string1               1    4
2    value 2              string 2              2    5
3    value 3              string 3              3    6
You could add 2 cross-rows with one value and change Display Value of one of them or use ProcessCell event if you need to add row number. You should know that the row number counts from first row of the whole cross-tab and starts from zero.

Please, look at the attached report template.
Report.mrt
(25.47 KiB) Downloaded 408 times
Thank you.

Re: adding a column to a cross tab report

Posted: Wed Feb 19, 2014 11:01 pm
by erikbrandvig
i have the line numbers. thanks!

now i'm trying to get another column into the cross tab... but i get a "total" or summary cell that i don't want... how can i get rid of that?

Image

Re: adding a column to a cross tab report

Posted: Fri Feb 21, 2014 11:05 am
by HighAley
Hello.

You should just set the Show Total property of the second row to False.
ShowTotal.png
ShowTotal.png (60.08 KiB) Viewed 3464 times
Thank you.