Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to use Calculated Member in CrossTab ??

Status
Not open for further replies.

ni23

IS-IT--Management
May 1, 2008
5
CA
-Crystal Report 2008

Below example shows individuals that buy bread and burger both or buy only one item. How I can use "Calculated Member" feature from CrossTab to create the column "Sandwich" that will show "1" if the individual bought both bread and burger or show "0" if the individual bought only one item??


Bread Burger Sandwich
Bobby 1 1 1
Cathy 0 1 0
Jenny 1 0 0


Thanks,

nir
 
I don't have CR2008, so am not familiar with this feature, but you could try creating a formula like this:

if distinctcount({table.item},{table.person}) = 2 then
"Sandwich" else
{table.item}

Then use this as your column field. You would have to have a group on {table.person} in your main report even if suppressed. Disclaimer: This is just a wild guess.

-LB
 
Calculated member is a cool feature. There are several pages on how to use them in our recent newsletter. There are a bunch of new Grid functions that take a bit of time to use, but are really powerful.

That will let you do what you want to.

Editor and Publisher of Crystal Clear
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top