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

Help to get minimum and maximum 1

Status
Not open for further replies.

twes3

Programmer
Jun 1, 2004
16
US
Need help with getting the minimum and maximum for a record location from my database. In my database an item can be in it twice. The difference is the record type which is either a '1' or '2'.

In my Crystal Report (ver10), I am grouping on the item. In my group footer I am displaying the item along with some other fields that I have to summarized. Now here is where my problem starts. I need to have 2 columns, one for the '1' record type(minimum) and one for '2' record type(maximum). I had a formula field where I was condition for the type that I needed but when the report fires it seems to only bring in the '1' type if the item is in there only 1 time and blank if the item is in there 2 times and my summarized field doubles in amount. My quantity SHOULD only be 1615. Below is my example:

Database record
Record Item Locn
Type Barcode
1 140190600 P201100403
2 140190600 P150010208

Crystal Report Group footer

Item Qty Locn1 Locn2
140190600 3230

What I am looking for is:

Item Qty Locn1 Locn2
140190600 1615 P201100403 P150010208

Thank you for looking and hopefully someone can figure this out.
 
Group by Item

Create two formual
@type1

If Type = 1 then Locn else ''

@type2

If Type = 2 then Locn else ''

Suppress details place ItemFiled in Group footer, with Max summaries of the two formula.
Cretae a Running total on the QTy field, and in the evaluate part of the RT set window check on change of Item No group. Place this RT in Item group footer.

Ian
 
Work like a charm!!!! Thank you IanWaterman.....
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top