Need to have a running total on Quantity by Order No Group.
1 - Item No, 2 - Dept No, 3 - Order No, Quantity
Here's Reset code: Placed in the Group Header for Item No
Whileprintingrecords;
Numbervar Amount := 0
Here's Qty code:
Whileprintingrecords;
If onfirstrecord or previous({SHOP_ORD_EFF.ORDER_NO})<>{SHOP_ORD_EFF.ORDER_NO} then
Numbervar Amount:= Amount + 1;
Here's Display code: Placed in the Group Footer
Whileprintingrecords;
Numbervar Amount;
It all works fine if I only have the two groups Item No and Order No, when I try to add another group Dept No the calculation is off.
The data I am working with for example:
Item No:; Dept No:; Order No:; Quantity:;
1234; 02; 10001; 0;
1234; 03; 10001; 0;
1234; 04; 10001; 0;
1234; 05; 10001; 10;
1234; 06; 10001; 0;
1234; 07; 10001; 10;
1234; 08; 10001; 0;
Total for Group Order No: 10
1234; 02; 10002; 0;
1234; 03; 10002; 0;
1234; 04; 10002; 0;
1234; 05; 10002; 1;
1234; 06; 10002; 0;
1234; 07; 10002; 1;
1234; 08; 10002; 0;
Total for Group Order No: 1
Total for Group Item No: 11
1235; 02; 10002; 0;
1235; 02-1; 10002; 19;
1235; 04; 10002; 0;
1235; 05; 10002; 19;
1235; 05-1; 10002; 0;
1235; 07; 10002; 0;
1235; 08; 10002; 19;
1235; 15; 10002; 0;
Total for Group Order No: 19
Total for Group Item No: 19
1236; 02; 10003; 1;
1236; 02-1; 10003; 0;
1236; 04; 10003; 1;
1236; 05; 10003; 1;
1236; 08; 10003; 1;
1236; 09; 10003; 1;
Total for Group Order No: 1
Total for Group Item No: 1
Don’t need total by dept no but need over all total by item no.
The quantity on the order is only 1 but can be worked in multiple departments but only want to show 1 not 3 or however many dept no’s there are. Once I add the department it counts it for each department.
Hope you can understand where I am trying to go.
Thanks in advance for the help,
Rbdan
1 - Item No, 2 - Dept No, 3 - Order No, Quantity
Here's Reset code: Placed in the Group Header for Item No
Whileprintingrecords;
Numbervar Amount := 0
Here's Qty code:
Whileprintingrecords;
If onfirstrecord or previous({SHOP_ORD_EFF.ORDER_NO})<>{SHOP_ORD_EFF.ORDER_NO} then
Numbervar Amount:= Amount + 1;
Here's Display code: Placed in the Group Footer
Whileprintingrecords;
Numbervar Amount;
It all works fine if I only have the two groups Item No and Order No, when I try to add another group Dept No the calculation is off.
The data I am working with for example:
Item No:; Dept No:; Order No:; Quantity:;
1234; 02; 10001; 0;
1234; 03; 10001; 0;
1234; 04; 10001; 0;
1234; 05; 10001; 10;
1234; 06; 10001; 0;
1234; 07; 10001; 10;
1234; 08; 10001; 0;
Total for Group Order No: 10
1234; 02; 10002; 0;
1234; 03; 10002; 0;
1234; 04; 10002; 0;
1234; 05; 10002; 1;
1234; 06; 10002; 0;
1234; 07; 10002; 1;
1234; 08; 10002; 0;
Total for Group Order No: 1
Total for Group Item No: 11
1235; 02; 10002; 0;
1235; 02-1; 10002; 19;
1235; 04; 10002; 0;
1235; 05; 10002; 19;
1235; 05-1; 10002; 0;
1235; 07; 10002; 0;
1235; 08; 10002; 19;
1235; 15; 10002; 0;
Total for Group Order No: 19
Total for Group Item No: 19
1236; 02; 10003; 1;
1236; 02-1; 10003; 0;
1236; 04; 10003; 1;
1236; 05; 10003; 1;
1236; 08; 10003; 1;
1236; 09; 10003; 1;
Total for Group Order No: 1
Total for Group Item No: 1
Don’t need total by dept no but need over all total by item no.
The quantity on the order is only 1 but can be worked in multiple departments but only want to show 1 not 3 or however many dept no’s there are. Once I add the department it counts it for each department.
Hope you can understand where I am trying to go.
Thanks in advance for the help,
Rbdan