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 Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using Select Expert on a Summarized Field

Status
Not open for further replies.
May 10, 2006
3
US
Is this possible??? I have a summary created such as a sum for a group of values and I need to use the select expert to not pull the zero values. Help...
 
Please post yoru software version.

Try using the Report->Selection Formulas->Group and place:

sum({table.field},{table.group}) <> 0

Forget about using the select expert.

-k
 
Actually, the Select Expert can be used on the summary field. You can select the summary with the mouse, then right click to invoke the Select Expert, and it will select correctly.

Because you will have selected a summary field, it will apply your request to the "Group Selection" formula instead of the Record Selection formula.

Editor and Publisher of Crystal Clear
 
That's true, Chelsea, I just suggest that people learn to code Crystal, as many thigns will not be done properly by the Select Expert, hence, forget about using it.

-k
 
Thanks for the help, first of all my version of Crystal Reports is 9.0 Developer version. The problem is I'm wanting to select specific values out of a summarized field and for instance I want to filter my report to show all values that are not equal to zero in the below formula.

Sum ({@MRP Amount w/zeros}, {IV00101.ITEMNMBR})-{IV00102.ATYALLOC}-Sum ({@Qty Issued w/ Zeros}, {IV00101.ITEMNMBR})

I can't use the record selection and when I use the group selection it tells me I can't because "the formula cannot be used because it must be evaluated later
 
I think you need to show the content of all nested formulas and also provide sample data and a little more explanation.

-LB
 
The nested formulas are as follows:
{@MRP Amount w/zeros}=if IsNull({PK010033.MRPAMOUNT_I}) then 0 else {PK010033.MRPAMOUNT_I}
{@Qty Issued w/ Zeros} = if IsNull({PK010033.QTY_ISSUED_I})then 0 else {PK010033.QTY_ISSUED_I}

I'm not sure what else you need, these 3 values are all numeric for instance 20.00, 6.00, and 5.00. I'm not quite sure why but it just seems that any time you subtract or add two summarized fields like I have above you are unable to create a selection requirement using the select expert. I don't know why this is and I'm looking for a work around.
 
If those are your formulas, then the following formula should work in the group selection area:

Sum ({@MRP Amount w/zeros}, {IV00101.ITEMNMBR})-{IV00102.ATYALLOC}-Sum ({@Qty Issued w/ Zeros}, {IV00101.ITEMNMBR}) <> 0

Make sure that you are going to report->selection formula->GROUP to enter this. This should return groups based on itemnumber where the result above <> 0.

For future reference (because this shouldn't be a problem in the current case), sometimes you cannot use nested formulas in group selection, but if you use the contents of the formula instead, group selection becomes available.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top