Group by QTY
<p class="ssiBODYCOPY">Hello Guys<br />I have a report with 10.000 records and I need to group by 50 groups.<br />How I can do that..?<br />Thanks for you help<br /></p>
<p>Another way that this is possible is to group on a formula. I have included the formula below. This formula is essentially a running total that occurs WhileREADINGRecords. This is the only way that we can use it to group on. The counter1 essentially behaves as a record counter. I would have used the RecordNumber function, but then the formula cannot be grouped on. The counter2 is the value that the formula outputs and essentially is what is being grouped on.</p><p><u><strong>Formula below:</strong></u> <br /></p><p>whilereadingrecords;</p><p>NumberVar Counter1;<br />NumberVar Counter2;<br /><br />//Assign the specified number to group on to the NumberToGroupOn variable.<br />NumberVar NumberToGroupOn := 50;</p><p>// The second value passed to the remainder function is the count of records per group<br />// that you want to fit. In this case it is the NumberToGroupOn variable<br />if remainder(Counter1,NumberToGroupOn) = 0 then <br />(<br />Counter1 := Counter1 + 1;<br />Counter2 := Counter2 + 1;)<br />else<br />(<br />Counter1 := Counter1 + 1;<br />Counter2;) </p><p> </p><p>Now you will group on this field. If you want to adjust the number from 50 to a 100 or something you will change the value being passed to the NumberVar NumberToGroupOn variable above.</p><p>Hope this helps.</p>Regards,<br />Sean
Similar Messages
-
9i,
I would like to Change Material Group in Material Masterdata through MM02.
But I have one doubt.Before Changing Material group I am tacking MC.9 Report for Stock statement.For Ecample in old Material group(xxxx) Some Stock is there 100.Like these Group XXXX qty 100.
Then I am change New Material group YYYY in XXXX Plance.Now i am tacking MC.9 Report For Stock Statement.Now i want new Material group wise Stock only like these group YYYY qty 100.
These is the My client Requirement.what cani do for thesemc.9 is standard infostructure and it has got its own update rules to update the infostrcture. It wont be possible to have a retrospective update of the infostructure internal tables, and so if you are trying to analyse it for past periods, results may be wrong.
-
Combining quantities of Two line items while calculating Free goods qty
Hi,
Scenario is: On every sales of 50 pieces( 50 pieces can be of different material like Mat A and Mat B) in single sales order,
5 pieces ( of Material A) should be given as Free goods.
Means: I want to total the quantities of all the line item before calculation of the Free goods.
Is it possible in SAP if yes, how to do it?
Regards
GauravHi,
I have one solution but I have not tried it. You can try.
What you can do is to group all the materials for which you want to give free goods
Add new field Material group from field catalogue to Condition table - create new condition table
create access seq and put this table in it, put acc. seq in cond. type, assign it to free goods determination
Create condition record, enter this material group and qty., I guess here system will total the qty of all the materials that you will enter in sales order assuming you have assigned mat. group in respective material master
Try this and post your feedback
If it works, it will be good for all friends having similar req.
regards,
Sagar -
Oracle Gurus,
I have defined pick grouping rule by itemwise, as per this parameter when I release sales orders.. should be picked up by itemwise.
Example:
Order Number Item Qty
100001 A 200
100001 B 111
100002 A 300
100002 B 222
100003 A 400
100003 B 333
I want to release all above order at same time, as per pickslip grouping rule only by Item.... System should pick as Item A as : Qty 900 and Item B as Qty 666.
System is creating pick slip as by orderwise and itemwise, totally 6 lines created...
My client dont want to go each and every time pick the same item, its waste of time.
If they get pickslip as Group as Qty 900 - Item A and Qty 666 - Item B - Picker goto respective subinventory pick the items.
How to do this setup to achieve my requirement.
Quick responses highly appreciated.Hi, I am trying to sort Pick slip grouping by Items however it is grayed out. Any idea, How can I make it enable?
-
Any ideas for this Business requirement
Hi All,
Just wondering to see if any of you have encountered the following business requirement and if so how we can address it.
Business Requirement:
(1) Distribution Centers(DC Plant) maintains a relationship with the Factory(Production Plant) that can allow for the swapping of planned production of one product with the planned production of another product. This relation can allow for the partial or complete swapping of one unit of planned production with another in the group.
Example: Product Group1 has 2 products underneath it- Product A and Product B
n= Current period (Month)
n+1= Next period.........
After n+4 periods, the production qty are as follows:
Prod qty@ Product A = 10
Prod qty@ Product B = 30
Hence the Production Qty@ Product Group 1 = 20+20 = 40 ( Aggregation of the prod qty from products to product group level)
The swap of production can be btw Product A and Product B and should not exceed the total Production Qty for the product group
Some examples can be:
Prod qty@ Product A = 15
Prod qty@ Product B = 25
Total Prod Qty@ Product group 1= 40
Prod qty@ Product A = 20
Prod qty@ Product B = 20
Total Prod Qty@ Product group 1= 40
Prod qty@ Product A = 30
Prod qty@ Product B = 10
Total Prod Qty@ Product group 1= 40
etc etc........lot of combinationsu2014The above examples are for understanding the requirement.
However let us say the business determines a planned % of swap btw the products:
Example:
Total Prod Qty@ Product group 1= 40
Swap % = 10%
Then the new Production Qty with the Swap% are as follows:
Prod qty@ Product A = 10 + (10*10/100) = 11
Prod qty@ Product B = 30 + ( 30*10/100) = 33
(2) The other requirement is that the ATP check of the Sales Orders should take into account the Production qty with swap% at the individual product level and also constrain it with the total production qty for the Product group
Example: Let us say we have a
SALES ORDER for Product A for Requested Qty=40
SALES ORDER for Product B for Requested Qty=40
The confirmation for the above 2 sales orders should be as follows:
Confirmation for SALES ORDER for Product A =11 qty
Confirmation for SALES ORDER for Product B =29 Qty
The total confirmation is still equal to the original production qty for the Product Group= 40 qty
Thanks
KumarKumar
I dont know what flexibility you have in building the solution - are you looking at a greenfield from-scratch solution or do you already have a ltechnical andscape that you need to work with ?
If its the former then here is what might work -
1. Using APO DP, you generate a 'Sales' Forecast (based on statistical models + adjustments). This is a statement of unconstrained independent demand, for the products they actually expect to sell.
2. Using SNP, you (optionally) check the sales forecast for capacity.
3. As part of the S&OP process, you make any adjustments in DP to develop a 'Consensus' (and optionally constrained) Demand Plan.
4. Within DP, in the very near term you disallow any changes to the Consensus Demand Plan ('Frozen' Horizon) since it would be too late for manufacturing to react to changes. In the medium term ('Slushy' horizon), you allow changes only within the Product Group, using the swapping process you describe. Further out (Liquid horizon), you follow steps 1 through 3, with any changes acceptable.
5. Usng GATP, you can use the same forecast created within step 1 or 4 to limit what can be ordered using Product Allocation.If the products within the product group are interchangeable from a customers perspective, then you can use Rules Based ATP to switch products.
Rishi Menon -
Creating a Purchase Order for the Asset
Hi,
Please see the following steps:
1.Create a purchase order for the asset.
2. Post a goods receipt from this PO.
3. Quantity of asset will be transfered from goods receipt.
But I find quantity of asset(AS02) was not be transfered and still was equal to 0.
Could you help me?
Thanks and Regards,
Colin.see the field status varient for the gl account see the qty field is optional field or not
and check in the asset group also qty field is the optional field
Assign point if useful
Regards
A.k -
Require following field from one function module
Hi,
This is a issue which I am working on.Can u help me in this issue The issue is as below.
It ia a Abaper related issue .They want the clarification from Functional side
We require your help in below mentioned Open order extractions. Basically we want to know.
Function modules for Open Sales/ Purchase order quantity and for open quantity
They also require the following field to be fetched in the table
Extraction for Open Purchase Order
Get all Purchase Order (EBELN) , Vendor (LIFNR) , Name (NAME1), Material (MATNR), Material Description (MAKTX), Material Group (MAKTL), Open Quantity (Order Qty (MENGE) - Received Qty(field)) > 0), Requested Date (BEDAT), Purchasing Group (EKGRP).
For Sales Organization Plant
PO No, Vendor, Vendor name, Material,Mat description, Mat group,Open qty,Requested date, Purchasing group
Thank youHi Sravanthi,
Maintain a table type in SE11 wich is of type your itab in the program to avoid type conflicts
you IMPORT EXPORT or SET PARA GET PARA
here you have to use the system table INDX(hk)
please go through the example provided in the KEY word documentaion
hope this will serve your purpose.
Regards
Ramchander Rao.K -
Hi All,
Can i get a standard QM reports showing the following data
Report 1 - Report showing Vendor,Quanity recied from vendor in a given period,Quantity accepted and defective quantity.This is somewhat similar to MCVI but MCVI does not show accepted quantity.
Report 2- A report in which a materail group and period is given in the selection criteria and we get the following output format
Material group Lot Qty Accept Qty Defect Qty
Please help
Edited by: Shreya Gautam. on Jan 27, 2010 11:50 AMHello,
MCVI shows accepted quantity also. But as far as my knowledge is concerned these QM LIS reports are not possible based on material group. In fact these prove more effective based on inspection type rather than material group.
I think you need to develop query or report through ABAP in order to have material group in picture.
Best Regards,
Anand Rao -
How to Use a single combo box to generate two graphs
Hi All,
I have my data as below
Company Group Week Qty
CP01 16 40/2010 200
CP01 16 41/2010 210
CP01 16 42/2010 220
CP01 16 43/2010 230
CP01 16 44/2010 240
CP01 16 45/2010 250
CP01 16 46/2010 140
CP01 8 40/2010 300
CP01 8 41/2010 310
CP01 8 42/2010 320
CP01 8 43/2010 330
CP01 8 44/2010 340
CP01 8 45/2010 350
CP01 8 46/2010 140
CH13 16 40/2010 100
CH13 16 41/2010 210
CH13 16 42/2010 220
CH13 16 43/2010 230
CH13 16 44/2010 240
CH13 16 45/2010 250
CH13 16 46/2010 260
CH13 8 40/2010 100
CH13 8 41/2010 310
CH13 8 42/2010 320
CH13 8 43/2010 330
CH13 8 44/2010 340
CH13 8 45/2010 350
CH13 8 46/2010 360
I have to display the company level qty for each week against the Group data. I have a combo box for the company and on selection my destination will have all rows with that company, and on the destination rows as a source for the second combo box to choose a smaller set of data for the group and I draw a line graph.
But the user wants a baseline Graph, for example If they choose CP01, all the groups 16 & 8 qty will be summed up by the company. So I will have CP01 for 40/2010 I will have 500 Qty (300+200) so the base column graph will be 500 and depending on the Group selection it will be either 300 or 200.
I am able to the Group within the Company, but unable to do the company baseline. I think it should be done within excel using it's functions, any idea would help.
Thanks,
Arthur.Hi Alex,
I have some work around for your issue with excel fucntion please go through the folowing logic and let me know if u hv any issues.
(ComGrpWeek)
Concatenate Company Group Week Qty
=G8&H8&I8 CP01 16 40/2010 200
=G9&H9&I9 CP01 16 41/2010 210
=G10&H10&I10 CP01 16 42/2010 220
=G11&H11&I11 CP01 16 43/2010 230
=G12&H12&I12 CP01 16 44/2010 240
=G13&H13&I13 CP01 16 45/2010 250
=G14&H14&I14 CP01 16 46/2010 140
=G15&H15&I15 CP01 8 40/2010 300
=G16&H16&I16 CP01 8 41/2010 310
=G17&H17&I17 CP01 8 42/2010 320
=G18&H18&I18 CP01 8 43/2010 330
=G19&H19&I19 CP01 8 44/2010 340
=G20&H20&I20 CP01 8 45/2010 350
=G21&H21&I21 CP01 8 46/2010 140
=G22&H22&I22 CH13 16 40/2010 100
=G23&H23&I23 CH13 16 41/2010 210
=G24&H24&I24 CH13 16 42/2010 220
=G25&H25&I25 CH13 16 43/2010 230
=G26&H26&I26 CH13 16 44/2010 240
=G27&H27&I27 CH13 16 45/2010 250
=G28&H28&I28 CH13 16 46/2010 260
=G29&H29&I29 CH13 8 40/2010 100
=G30&H30&I30 CH13 8 41/2010 310
=G31&H31&I31 CH13 8 42/2010 320
=G32&H32&I32 CH13 8 43/2010 330
=G33&H33&I33 CH13 8 44/2010 340
=G34&H34&I34 CH13 8 45/2010 350
=G35&H35&I35 CH13 8 46/2010 360
Solution:
Company Group Week Qty (Formaule) Actual values
CP01 16 40/2010 =SUMIF($F$8:$F$35,$M$9&$N$9&O9,$J$8:$J$35) 200
41/2010 =SUMIF($F$8:$F$35,$M$9&$N$9&O10,$J$8:$J$35) 210
42/2010 =SUMIF($F$8:$F$35,$M$9&$N$9&O11,$J$8:$J$35) 220
43/2010 =SUMIF($F$8:$F$35,$M$9&$N$9&O12,$J$8:$J$35) 230
44/2010 =SUMIF($F$8:$F$35,$M$9&$N$9&O13,$J$8:$J$35) 240
45/2010 =SUMIF($F$8:$F$35,$M$9&$N$9&O14,$J$8:$J$35) 250
46/2010 =SUMIF($F$8:$F$35,$M$9&$N$9&O15,$J$8:$J$35) 140
40/2010 =SUMIF($F$8:$F$35,$M$9&$N$9&O16,$J$8:$J$35) 200
8 40/2010 =SUMIF($F$8:$F$35,$M$9&$N$17&O17,$J$8:$J$35) 300
41/2010 =SUMIF($F$8:$F$35,$M$9&$N$17&O18,$J$8:$J$35) 310
42/2010 =SUMIF($F$8:$F$35,$M$9&$N$17&O19,$J$8:$J$35) 320
43/2010 =SUMIF($F$8:$F$35,$M$9&$N$17&O20,$J$8:$J$35) 330
44/2010 =SUMIF($F$8:$F$35,$M$9&$N$17&O21,$J$8:$J$35) 340
45/2010 =SUMIF($F$8:$F$35,$M$9&$N$17&O22,$J$8:$J$35) 350
46/2010 =SUMIF($F$8:$F$35,$M$9&$N$17&O23,$J$8:$J$35) 140
40/2010 =SUMIF($F$8:$F$35,$M$9&$N$17&O24,$J$8:$J$35) 300
Simple funda here is jst concatenate the Company code + group + Week
Now at solution write a sumif function the range will be the concatenated values and sum range will be the Qty.
Let me know if you have any issues in implementing thsi logic.
Regards,
Anjanikumar C.A. -
Hello,
When ever the po undergoes a change we want to communicate the entire PO details via EDI to the vendor. Especially with old and new quantities and all other details. If anyone of you come across such a scenario please let me know.
Thanks in advance,
SriniHi Srinivas ,
If you could tell us what changes you wish to pass on , as far as your query i think this will help you .
Use these
D93A.ORDCHG
Segment group 16: QTY-DTM
Condition: C,10
A group of segments to specify the scheduled quantities,date/time/period of the schedule.
QTY, Quantity
Condition: M,1
A segment to specify pertinent quantities relating to the scheduleand pattern established in the SCC segment, i.e. deliveryquantity.
C186 QUANTITY DETAILS M
| 6063 Quantity qualifier M an1..3
| 6060 Quantity M n1..15
| 6411 Measure unit qualifier C an1..3
regards
kp -
Default VAT code in the PO Releases.
Hi All,
Is there a way to give a default VAT code in the Blanket Purchase Agreements,so that the VAT code is come automatically when we release the items.
Otherwise we need to enter a VAT code for each and every item.
Thanks,
Migara.Hi
Tcode: ME11
enter the vendor, purachse organisation and plant.
in the next screen enter the description of info record, material group, order unit and sort term (helpful in search).
In the next screen enter details like planned delivery time, purchase group, standard qty, tax code and net price and save.
regards
girish
Edited by: Gbettaiah on Aug 3, 2011 8:37 AM -
Hi,
Can any one help me on this issue, I am working production support. For quality cube if one of the notificationss 10044059 Problem Group is updated in sap. It is loading with updated record in the cube through ODs but when I execute the report it is displaying old and new Problem Group for one notification as below.
Notification,Created On, Priority,status, Problem Group,Def.Qty. Int
10044059, 10/4/2006, DEF./MANUF.MINOR, CNK-PROD, 6.000 EA
10044059, 10/4/2006, DEF./MANUF.MINOR, CN-OE, 6.000 EA
10044328, 10/4/2006, DEF./MANUF.MINOR, CN-OE, 10.000 EA
10044411, 10/4/2006, DEF./MANUF.MINOR, CN-OE, 10.000 EA
10044411, 10/4/2006, DEF./MANUF.MINOR, CN-PROD, 10.000 EA
The client wants it has to display latest Problem Group "CN-OE" for the notification "10044059". The problem Group "CNK-PROD" record should not to display because that is old one.
Please any one let me know how to do this.
Thanks in advance,
Raj.Hi Ravi,
I have verified in ODS the problem group is data part and Overwrite is there already in ODS. In First delta load it has loaded as below. Then to CUBE
Notification,Created On, Priority, Problem Group,Def.Qty. Int
10044059, 10/4/2006, DEF./MANUF.MINOR, CNK-PROD, 6.000 EA
And after two days the problem group has updated as CN-OE in SAP and in next delta it has loaded as below into ODS and it is got overwritten in ODS and it has moved to cube.
Notification,Created On, Priority, Problem Group,Def.Qty. Int
10044059, 10/4/2006, DEF./MANUF.MINOR, CN-OE, 6.000 EA
But when I run the query it is displaying two records for notification from the cube.
Notification,Created On, Priority, Problem Group,Def.Qty. Int
10044059, 10/4/2006, DEF./MANUF.MINOR, CNK-PROD, 6.000 EA
10044059, 10/4/2006, DEF./MANUF.MINOR, CN-OE, 6.000 EA
The Notification has to display only one record with latest Problem group with CN-OE.
Thanks,
Raj. -
select distinct kmt.tag_number , fa.tag_number from kfupm_mcr_tag kmt, fa_additions fa
where kmt.TAG_NUMBER = fa.TAG_NUMBER
SUBSTR( tag_number, 1,6) tag_number;
can any one help me out
Thanks
Arifuddin
Edited by: user11309801 on Jan 1, 2011 8:28 AMThanks it's working.
select distinct SUBSTR( kmt.tag_number, 1,6) from kfupm_mcr_tag kmt, fa_additions fa
where kmt.TAG_NUMBER =fa.TAG_NUMBER
and
select itm.inventory_item_id "Item#",itm.segment1,itm.description,qty.SUBINVENTORY_CODE as SHI,
sum(qty.primary_transaction_quantity) "On Hand Qty"
from MTL_ONHAND_QUANTITIES_DETAIL qty,
mtl_system_items itm
WHERE itm.inventory_item_id=qty.inventory_item_id
and itm.ORGANIZATION_ID=qty.ORGANIZATION_ID
and qty.SUBINVENTORY_CODE IN ('ITC-8888', 'ITC-9999')
and trunc(qty.last_update_date) <=:P_DATE_FROM
AND trunc(SYSDATE) >=:P_DATE_TO
group by qty.SUBINVENTORY_CODE,itm.inventory_item_id,itm.segment1,itm.description;
guide me solve the above
Regards
Arifuddin
Edited by: user11309801 on Jan 1, 2011 8:54 AM -
select itm.inventory_item_id "Item#",itm.segment1,itm.description,qty.SUBINVENTORY_CODE as SHI,
sum(qty.primary_transaction_quantity) "On Hand Qty"
from MTL_ONHAND_QUANTITIES_DETAIL qty,
mtl_system_items itm
WHERE itm.inventory_item_id=qty.inventory_item_id
and itm.ORGANIZATION_ID=qty.ORGANIZATION_ID
and qty.SUBINVENTORY_CODE IN ('ITC-8888', 'ITC-9999')
and trunc(qty.last_update_date) <=:P_DATE_FROM
AND trunc(SYSDATE) >=:P_DATE_TO
group by qty.SUBINVENTORY_CODE,itm.inventory_item_id,itm.segment1,itm.description;
select distinct SUBSTR( kmt.tag_number, 1,6), fa.model_number from kfupm_mcr_tag kmt, fa_additions fa
where kmt.TAG_NUMBER =fa.TAG_NUMBER ;
and fa.model_number is not null;
union all is not working.
Regards
ArifuddinWhile using the set operators, to match the number of columns in the SELECT list you can make use of NULL as:
SELECT COL_NAME1,COL_NAME2,COL_NAME3
FROM TAB_NAME1
UNION
SELECT COL_NAME1,COL_NAME2,NULL
FROM TAB_NAME2The columns in the both SELECT lists should be same and also the datatype. The resultant of the query will be the columns of first SELECT list (column aliases) -
PO Qty in SKU configuration for specific Material Group in PO
Dear All,
I face issue when I do MIGO, which is that unit measure KG can not covert to stockunitstock unit measure PC.
After I checking, I found the following information in tab Qualities/Weights of PO:
PO Quantity 2 PC Order Unit <-> Ord. Price Unit PC <-> KG
PO Qty in SKU 0.000 Order Unit <-> SKU 0 PC <-> 0
What I can configure is "Order Unit <-> Ord. Price Unit PC <-> KG", but I can not conifgure "Order Unit <-> SKU" for PO to buy material group rather than sepcific material.
Could anybody can tell me how to configure "PO Qty in SKU 0.000 Order Unit <-> SKU 0 PC <-> 0" for PO to buy material group in ME21N?
I am looking forward to your kind suggestion, which is really appreciated!
Cheers!Does anyone face the same issue before? could you give me any tips if you have such problem? thanks in advance!
Maybe you are looking for
-
Remove automatic credit block in sales order
Gurus, How can I remove credit block in sales order for specific sales organization/sales area? Thanks in advance Raj
-
SR510 Lock-in Amplifier Repeated Data Output Command Problem
Hi, I'm using LabVIEW version 7.1 with an SR510 lock-in amplifier connected through GPIB-488.2. I've gotten past most of the hurdles, the device appears in MAX and I can send and recieve data using the VISA test panel. My main goal is to be able to h
-
Custom close / exit button in HTML widget
Hi, how to set a custom close / exit button in a HTML widget for iBooks Author? I want to replace or hide the standard button in the top left corner. I already tried some JavaScript but nothing seems to work so far. Where can this button be modified
-
Does any Implemented SAP FIORI in ECC + Gateway Server
Hi Folks, Does any one implemented SAP FIORI Apps in below scenario where ECC (ODdata components) in Sand box and Gatewayserver (UI Components) Sand box as separate machines? We have configured Odata component (gbapp_poapproval) in ECC, and UI Compon
-
Crystal reports connection refused
Hello BW Experts, While trying to connect SAP BW from Crystal we are getting this error Database connector Error: BAPI Error #:0 Error occurred when starting the parser : Error opening a RFC Connection. Does this mean the RFC connection is broken.