Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Hi! Does anybody know from which table to take base quantity for production orders?

manole_apetroaie
Participant
0 Kudos

does anybody know from which table to take base quantity for production orders? i think is in AFVV-MGVRG but i am not sure. Thank you !

Kind regards, Julian

I need it in the structure below:

TYPES: BEGIN OF tables_fields,





  AUFNR TYPE AUFK-AUFNR, "Nr comanda productie

*   AUFNR TYPE AUFM-AUFNR, "Nr comanda productie

*  MAKTX TYPE MAKT-MAKTX, "Descriere material

  AUART TYPE AUFK-AUART, "Tip comanda /Sectie

  WERKS TYPE AUFK-WERKS, "Unitate logistica

  TXT   TYPE T003P-TXT,  "Nume sectie

  "MENGE TYPE AUFM-MENGE, "Cantitate buc predata

  GAMNG TYPE AFKO-GAMNG, "Cantitatea totala vrac

  GMEIN TYPE AFKO-GMEIN, "Unitatea de masura kg cantitate totala

  "WEMNG TYPE AFPO-WEMNG, "Cantitatea totala livrata

  ERFMG TYPE AUFM-ERFMG, "Cantitatea totala livrata defalcata

  GSTRP Type AFKO-GSTRP, "Data lansarii comenzii

  GLTRP TYPE AFKO-GLTRP, "Data estimativa a finalizarii comenzii

  BLDAT TYPE AUFM-BLDAT, "Data finalizarii comenzii

  MGVRG TYPE AFVV-MGVRG, "Bucati pe comanda-cant de baza

  "MEINS TYPE AUFM-MEINS,"Unitate bucati pe comanda-rectificat

  MEINH TYPE AFVV-MEINH,  "Unitate de masura bucati pe comanda

  MENGE TYPE AUFM-MENGE, "Cantitate buc predata

*  BMENG TYPE STKO-BMENG, "Cantitatea de baza estimata

*  BMEIN TYPE STKO-BMEIN, "Unitatea de masura cantitatea de baza estimata

  MATNR TYPE AUFM-MATNR, "Cod material

  "PLNBEZ TYPE AFKO-PLNBEZ,"Cod material

  MAKTX TYPE MAKT-MAKTX, "Descriere material

   MBLNR TYPE AUFM-MBLNR,

  ZEILE TYPE AUFM-ZEILE,

  BMSCH TYPE AFVV-BMSCH,

  SPRAS TYPE T003P-SPRAS,"Restrictionare limba

  ZILEDEP TYPE I,"AFKO-GLTRP, "Filtru date intre care s-au realizat comenzi

  COMDEP(10) TYPE C,"Nr zile comanda depasita

  COMINTRE TYPE AFKO-GSTRP,"Data comenzi termen depasit

* ERDAT TYPE AUFK-ERDAT, "Data lansarii comenzii - campul vechi

* LTRMI TYPE AFPO-LTRMI, "Data finalizarii comenzii noul camp

 "ISTAT TYPE TJ02T-ISTAT,

  "TXT04 type TJ02T-TXT04, "Text scurt stare comanda

  "TXT30 TYPE TJ02T-TXT30, "Text lung stare comanda

  line_color(4) TYPE c,



   END OF tables_fields.

1 ACCEPTED SOLUTION

manole_apetroaie
Participant
0 Kudos

it seems that the base quantity is calculated by AFPO-PSMNG / AFPO-UMREN. in this case the result is same as base quantity.

19 REPLIES 19

SimoneMilesi
Active Contributor
0 Kudos

You should explain your scenario and which is your aim: the question is pretty... vague.

Jelena
Active Contributor

I'm also curious who is "Julian" since the profile name says differently.

JL23
Active Contributor

the question in stack overflow is without Julian (after a moderator edited it away)

manole_apetroaie
Participant
0 Kudos

Dear Simone,

Thank you so much for your reply.Please find below my scenario which i need to bring in my alv report.:

thank you for your reply. The requierement is that i need to bring the base quantity from a production process into my report along with :plant(AUFK-WERKS), type of command (AUFK-AUART),section name (T003P-TXT),material(AUFM-MATNR),required base quantity(AFVV-MGVRG),unit measure(AFVV-MEINH),quantity produced(AUFM-MENGE),required quantity in KG(AFKO-GMEIN),quantity in KG produced(AUFM-ERFMG),date launch order(AFKO-GSTRP),estimated date finish order(AFKO-GLTRP),date effectively finish order(AUFM-BLDAT)

SimoneMilesi
Active Contributor
0 Kudos

It seems to me you are doing a copy-and-paste around the web without knowing what you are doing.

You are asking for something you already know and have....

manole_apetroaie
Participant
0 Kudos

If i would have known i wouldn`t have posted this here.

SimoneMilesi
Active Contributor
0 Kudos

This is your question

does anybody know from which table to take base quantity for production orders? i think is in AFVV-MGVRG but i am not sure. Thank you !

and this the requirement you have

 The requierement is that i need to bring the base quantity from a production process into my report along with :plant(AUFK-WERKS), type of command (AUFK-AUART),section name (T003P-TXT),material(AUFM-MATNR),required base quantity(AFVV-MGVRG),

What am i missing?

Your requirement states which table and field to read and you asked for it!

manole_apetroaie
Participant
0 Kudos

simone.milesi , i am the one who wrote the requirment ,what i don`t know if that is the correct table and field , i have process orders that show correctly the result and for others dont.

SimoneMilesi
Active Contributor

Ok, maybe i -finally- understood which field you are looking for: are you referring to this?

If yes, it's on AFKO-BMENGE.

HINTS FOR NEXT TIME

  1. Explain very well with examples and screenshots what you are looking for!
  2. Before posting, go to the standard transaction handling the data you need to manage, identify the field you want to extract, press F1 and then choose "Technical Information": 95% of times you can see the related table-field/domain/structure you need and with a little investigation on SE11/Google you'll find the answer by yourself. This way you start to understand also the links between the tables (at least the main ones).

0 Kudos

Dear Simone,

Thank you for your answer. In my table AFKO there is no field BMENGE neither other field that would hold the value that i am looking. I already did what you advised about pressing F1 on the field but in my case is pointing me to a structure for which i have difficulties in finding the table,please find picture attached.

0 Kudos

Neither on view CAUFV? Which release are you working on?

in my 731 i have that field on AFKO.

0 Kudos

Neither on view CAUFV.I`m on ecc.6.0

0 Kudos

Last attempt could be to debug CO03 and put a watch point on that field

0 Kudos

I tried to debug it using se38 and it says that it doesn`t exist.Thank you for your concern.

Jelena
Active Contributor
0 Kudos

I'm not familiar with the language but visually there is no such field on that screen in our system. (Please try to post the screenshots in English, you can choose a language when logging in.) We do have AFKO-BMENGE in DB, just like Simone mentioned. My guess would be your system is configured differently, therefore I doubt the SCN members will be able to answer this question.

There are only 3 main tables for production order: AUFK, AFKO, AFPO. Simply by checking SE16 you can probably figure out the source field, unless it's derived at runtime and not actually stored in the database.

JL23
Active Contributor

AFKO-BMENGE is only there if you have the include MILL_OC_AFKO, which means probably after activation of a business function or in a specific Industry solution

My approach in such cases is to take the field name and search for OSS notes. CAUFVD-BMENGE returned 6 notes and in note 1847303 it is said that SAP calculates the base quantity when the user changed the unit of measure in the header while creating the production order and entered a unit which is not equal to the base unit of measure.

The pop-up for technical field help allows forward navigation by double click, this way you may find where it is calculated and to which field and table it is updated, sometimes the screen fields have different names than the table fields.

SimoneMilesi
Active Contributor
0 Kudos

i didn't know that, thanks for the sharing!

Sadly who implemented our system (3 years before my arrival here) activated a lot of solutions and modules without a reason and it's hard to disentangle between them. 😞

0 Kudos

@Jurgen L. Thank you for your reply you were close. I updated the answer to this question.

manole_apetroaie
Participant
0 Kudos

it seems that the base quantity is calculated by AFPO-PSMNG / AFPO-UMREN. in this case the result is same as base quantity.