on 09-12-2016 6:31 PM
Dear Gurus,
Could you please provide all of the logic that is used to calculate the key figures in 0IC_C03. My task is to re-create these KF's in a HANA Calculation View, but I do not have the logic and I can't find it anywhere online (I have literally searched for hours).
0RECVS_VAL
0ISSVS_VAL
0ISSBLOSTCK
0ISSCNSSTCK
0ISSQMSTCK
0ISSTRANSST
0RECBLOSTCK
0RECCNSSTCK
0RECQMSTCK
0RECTRANSST
0ISSSCRP
0ISSVALSCRP
0RECTOTSTCK
0ISSTOTSTCK
0ISSVALSTCK
0RECVALSTCK
0VENCONCON
0RECVALQM
0RECVALBLO
0RECTRFSTVA
0RECCCNSVAL
0ISSVALBLOC
0ISSCCNSVAL
0ISSVALQM
0ISSTRFSTVA
For example, I did find a mention of the following for 0RECVS_VAL . I would like this exact same logic for all of the KF's listed above (and any others that may be missing).
IF ( SOURCE_FIELDS-BWVORG EQ '000' "Other Receipts
OR SOURCE_FIELDS-BWVORG EQ '001' "Goods Receipt / Vendor
OR SOURCE_FIELDS-BWVORG EQ '004' "Material Transfer / Receipt
OR SOURCE_FIELDS-BWVORG EQ '005' "Stock Adjustment InvD
OR SOURCE_FIELDS-BWVORG EQ '006' "Stock Adjustment Other
OR SOURCE_FIELDS-BWVORG EQ '010' ) "Receipt from Stock Transfer
AND SOURCE_FIELDS-bwapplnm EQ 'MM'
AND SOURCE_FIELDS-BWBREL EQ '1'
AND SOURCE_FIELDS-BWGEO <> 0
AND ( SOURCE_FIELDS-BSTTYP IS INITIAL
OR ( SOURCE_FIELDS-BSTTYP CA 'EQ' AND
SOURCE_FIELDS-KZBWS CA 'AM' ) )
It's truly so frustrating that such standard information is impossible to find. Please do not refer me to links, I have looked at them all, they are not helpful. Instead, to be very helpful, please copy and paste the straight text in your answer. Thank you so much.
Hi Karen,
Sometimes its easy to miss the obvious.
Can you install the "vanilla" or unmodified business content a Sandbox system?
You could review the "in BW" ABAP routines provided by SAP and get an idea of the underlying logic.
John Hawk
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This link seems to at least include the text from the Rule Groups, I think it's as close as I'm going to get. If anyone else has different text in their Rule Groups, please feel free to share.
Another helpful link, this time including 2LIS_03_UM:
This is the result of my research. I hope it helps other people who are facing similar issues! I still haven't figured out why 0ISSSCRP is not Stock-Relevant, does anyone know?
FIELD | RULE | ROUTINE | PROCESSKEY | BWAPPLNM | STOCKTYPE | STOCKCAT | STOCKRELEV | CQPUABU | CPPVLC |
0ISSVS_VAL | 02 | 0010 | 100, 101, 104, 105, 106, 110, 102, 103 | MM, IS-R | IS INITIAL OR (E, Q AND INDSPECSTK IN A, M) | 1 | <>0 | ||
0RECVS_VAL | 02 | 0011 | 000, 001, 004, 005, 006, 010, 002, 003 | MM, IS-R | IS INITIAL OR (E, Q AND INDSPECSTK IN A, M) | 1 | <>0 | ||
0ISSTOTSTCK | 03 | 0033 | 100, 101, 104, 105, 106, 110, 102, 103 | MM, IS-R | 1 | <>0 | |||
0RECTOTSTCK | 03 | 0034 | 000, 001, 004, 005, 006, 010, 002, 003 | MM, IS-R | 1 | <>0 | |||
0ISSVALSTCK | 03 | 0035 | 100, 101, 104, 105, 106, 110, 102, 103 | MM, IS-R | IS INITIAL OR (E, Q AND INDSPECSTK IN A, M) | 1 | <>0 | ||
0RECVALSTCK | 03 | 0036 | 000, 001, 004, 005, 006, 010, 002, 003 | MM, IS-R | IS INITIAL OR (E, Q AND INDSPECSTK IN A, M) | 1 | <>0 | ||
0VENCONCON | 04 | 0037 | 100, 101, 104, 105, 106, 110, 102, 103 | MM, IS-R | K | 1 | <>0 | ||
0ISSBLOSTCK | 05 | 0013 | 100, 101, 104, 105, 106, 110, 102, 103 | MM, IS-R | D | <> K, <> R | 1 | <> 0 | |
0RECBLOSTCK | 05 | 0018 | 000, 001, 004, 005, 006, 010, 002, 003 | MM, IS-R | D | <> K, <> R | 1 | <> 0 | |
0ISSQMSTOCK | 05 | 0017 | 100, 101, 104, 105, 106, 110, 102, 103 | MM, IS-R | B, L, O, R | <> K, <> R | 1 | <> 0 | |
0RECQMSTCK | 05 | 0015 | 000, 001, 004, 005, 006, 010, 002, 003 | MM, IS-R | B, L, O, R | <> K, <> R | 1 | <> 0 | |
0ISSTRANSST | 05 | 0023 | 100, 101, 104, 105, 106, 110, 102, 103 | MM, IS-R | F, H | 1 | <> 0 | ||
0RECTRANSST | 05 | 0024 | 000, 001, 004, 005, 006, 010, 002, 003 | MM, IS-R | F, H | 1 | <> 0 | ||
0ISSSCRP | 05 | 0029 | MVT: 551, 552, 553, 554, 555, 556 | MM | |||||
0ISSVALSCRP | 06 | 0030 | MVT: 551, 552, 553, 554, 555, 556 | MM | <> 0 | ||||
0ISSCNSSTCK | STD | 0012-1 | 100, 101, 104, 105, 106, 110, 102, 103 | MM, IS-R | K | 1 | <>0 | ||
0ISSCNSSTCK | STD | 0012-2 | 100, 101, 104, 105, 106, 110, 102, 103 | MM, IS-R | K, L, M | 1 | <>0 | ||
0RECCNSSTCK | STD | 0014-1 | 000, 001, 004, 005, 006, 010, 002, 003 | MM, IS-R | K | 1 | <>0 | ||
0RECCNSSTCK | STD | 0014-2 | 000, 001, 004, 005, 006, 010, 002, 003 | MM, IS-R | K, L, M | 1 | <>0 | ||
0RECVS_VAL | REV | 0001 | 050','051','052' | MM | <>0 | ||||
0ISSVS_VAL | REV | 0002 | 150','151','152' | MM | <>0 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Karen,
The question: "Why is 0ISSSCRP is not Stock-Relevant" is best directed at an MM forum, but with 20 years of getting data from MM , I'll take a stab a it.
Scrap, by its definition is unusable and has no economic value. Under GAAP (generally accepted accounting principals), it must be valued at zero. Though is may be useful to account for the physical object in the system until actual, physical destruction (think defective aircraft parts under investigation) , the scrap material should not be included in any "available for use" calculation. This is probably the reason it is not stock relevant.
Nice work on the matrix.
John Hawk
Good morning John,
I do appreciate the links that you sent, some of them were interesting for other reasons. As I originally stated, I knew it would be difficult to find the exact information I'm looking for. All I want is the logic of how to code the Rule Groups.
P.S. Good suggestion, but due to budget cuts, we don't have a Sandbox system.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Karen,
It sounds as though you want the source code for 2LIS_03_BX, 2LIS_03_BF , and 2LIS_03_UM to recreate in SAP HANA. I would not advise proceeding in this way.
Consider mapping the output of 2LIS_03_BF and 2LIS_03_UM into cumulative (standard) key figures into Advanced DSOs with a union in a Composite InfoProvider.
You could then save to the native HANA, if desired.
This would allow you to see the inventory at any point in time by selecting a range (begging of time - point time time desired) and using a simple SUM function. No initialization with 2LIS_03_BX required.
Be sure to review the the SAP Notes on the two extractors to identify the key fields.
(I won't provide any links, as requested.)
Please don't forget to record your final solution and to mark the question as answered.
Good luck,
John Hawk
I
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you for your answer John! We are actually using the standard extractors and a cube, exactly for the point-in-time reasons you mentioned. Because of the volume however, we could not use the standard Rule Groups -- we added that logic into the End Routine instead for the KF's that we needed at the time.
Now we have a new requirement is to isolate Scrap Inventory. I can't do that if I don't know how to identify Scrap Inventory, and the Rule Group logic is long gone. It's also a good time to add the other KF's that were deleted. Identifying the KF's themselves was relatively easy, but I can't find any info on how the KF's are calculated.
Hi Karen,
I don't have an SAP system to work so I can't verify my memory.
Most of the key figure used in 0IC_C03 are restricted key figures which are calculated during extract to mimic the materiel master display through MM03 and MB5B and passed to BW.
One would have to recreated the underlying function module to replicate the results in native HANA.
If you look at the SAP help
Material Movements from Inventory Management - Inventory Management - SAP Library
You will see a field from the datasource 2LIS_03_BF :
InfoObject 0INDSPECSTK
Description Valuation Special Stock
Data Element INDSPECSTK
Field in the DataSource KZBWS
I believe this special stock indicator will determine "scrap" inventory as a characteristic in a restriction.
This link provides a nice summary of special stock
Note: from Material Movements from Inventory Management - Inventory Management - SAP Library
The data record belonging to extractor 2LIS_03_BF is defined in a unique way using the key fields Material Document Number (MBLNR), Material Document Year (MJAHR), Item in Material Document (ZEILE), and Unique Identification of Document Line (BWCOUNTER).
You may wish to review SAP Note 1548125 - Interesting facts about Inventory Cubes
It has been updated for HANA optimized InfoCubes.
https://launchpad.support.sap.com/#/notes/1548125
Also
I'm not sure I understand "Because of the volume however, we could not use the standard Rule Groups"
It might be helpful if you elaborated
Please don't forget to record your final solution and to mark the question as answered.
Good luck,
John Hawk
User | Count |
---|---|
82 | |
11 | |
8 | |
7 | |
6 | |
6 | |
6 | |
6 | |
6 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.