SAP table S012 (Purchasing)

SAP table S012 has 15 primary key fields being MANDT,SSOUR,VRSIO,SPMON,SPTAG,SPWOC,SPBUP,EKORG,LIFNR,MATNR,WERKS,ESOKZ,MATKL,INFNR,LAND1.

If you're only analyzing data from a single SAP instance you may omit field MANT in your relationships as it will we the same across the entire dataset. On the other hand, if you're combining data from multiple SAP instances you need to take MANDT into account.

Field Description Data Type Length Decimals Checktable Data Element
MANDT Client CLNT 3 0 T000 MANDT
SSOUR Statistic(s) origin CHAR 4 0 SSOUR
VRSIO Version number in the information structure CHAR 3 0 * VRSIO
SPMON Period to analyze - month NUMC 6 0 SPMON
SPTAG Period to analyze - current date DATS 8 0 SPTAG
SPWOC Period to analyze - week NUMC 6 0 SPWOC
SPBUP Period to analyze - posting period NUMC 6 0 SPBUP
EKORG Purchasing organization CHAR 4 0 T024E EKORG
LIFNR Vendor's account number CHAR 10 0 LFA1 ELIFN
MATNR Material Number CHAR 40 0 MARA MATNR
WERKS Plant CHAR 4 0 T001W EWERK
ESOKZ Purchasing info record category CHAR 1 0 ESOKZ
0 Standard
1 Chargeable
2 Consignment
3 Subcontracting
P Pipeline
MATKL Material Group CHAR 9 0 T023 MATKL
INFNR Number of purchasing info record CHAR 10 0 EINA INFNR
LAND1 Country/Region Key of Supplier CHAR 3 0 T005 MCLANDL
PERIV Fiscal Year Variant CHAR 2 0 * PERIV
VWDAT Pointer to administrative data NUMC 10 0 VWDAT
BASME Base Unit of Measure UNIT 3 0 T006 MEINS
HWAER Local Currency CUKY 5 0 TCURC HWAER
MENGE Purchase order quantity QUAN 15 3 MC_MENGE
WEMNG Quantity of goods received QUAN 15 3 MC_WEMNG
WEMGM Goods receipt qty in base unit (calculate wtd.delivery time) QUAN 15 3 MC_WEMGMAX
REMNG Invoice receipt quantity QUAN 15 3 MC_REMNG
LSMNG Target delivery quantity in base unit of measure QUAN 15 3 MC_LSMNG
NETWR Effective order value CURR 15 2 MC_EFFWR
REWRT Invoice Amount CURR 15 2 MC_REWRT
ABSTP Number of purchase order items DEC 9 0 MC_ABSTP
ABSTE Number of purchase order item schedule lines DEC 9 0 MC_ABSTE
AANFP Number of requests for quotation items DEC 9 0 MC_AANFP
AANGP Number of Quotation Items DEC 9 0 MC_AANGP
AKONP Number of contract items DEC 9 0 MC_AKONP
ALFPP Number of scheduling agreement items DEC 9 0 MC_ALFPP
ALFPE Number of delivery schedules DEC 9 0 MC_ALFPE
ALIEF Number of deliveries DEC 9 0 MC_ALIEF
MABW1 Deviation 1 in the quantity delivered DEC 9 0 MC_MABW1
MABW2 Variance 2 in the quantity delivered DEC 9 0 MC_MABW2
MABW3 Variance 3 in the quantity delivered DEC 9 0 MC_MABW3
MABW4 Variance 4 in the quantity delivered DEC 9 0 MC_MABW4
MABW5 Variance 5 in the quantity delivered DEC 9 0 MC_MABW5
TABW1 Delivery date variance 1 in days DEC 9 0 MC_TABW1
TABW2 Delivery date variance 2 in days DEC 9 0 MC_TABW2
TABW3 Delivery date variance 3 in days DEC 9 0 MC_TABW3
TABW4 Delivery date variance 4 in days DEC 9 0 MC_TABW4
TABW5 Delivery date variance 5 in days DEC 9 0 MC_TABW5
LFZTA Total delivery time in days DEC 13 0 MC_LFZTA
LFZTG Weighted total delivery time DEC 15 1 MC_LFZTG
MENGE_R Order quantity (returns) QUAN 15 3 MC_MENGE_R
REMNG_R Invoice receipt quantity of returns QUAN 15 3 MC_REMNG_R
WEMNG_R Goods receipt quantity of returns QUAN 15 3 MC_WEMNG_R
REWRT_R Invoice amount: Returns CURR 15 2 MC_REWRT_R
EFFWR_R Effective order value of returns CURR 15 2 MC_EFFWR_R
WEWRT Value of goods received in local currency CURR 13 2 MC_WEWERT
REMNG_B Invoice receipt quantity as at posting date QUAN 15 3 MC_REMNG_B
WEWRT_B Goods receipt value as at posting date CURR 15 2 MC_WEWRT_B
REWRT_B Invoice Amount as at Posting Date CURR 15 2 MC_REWRT_B
REMNG_R_B IR quantity: Returns as at posting date QUAN 15 3 MC_REMNG_R_B
REWRT_R_B IR value: Returns as at posting date CURR 15 2 MC_REWRT_R_B
WEWRT_R_B GR value: Returns as at posting date CURR 15 2 MC_WEWRT_R_B

S012 foreign key relationships

Table Field Check Table Check Field
0 S012 BASME T006 Units of Measurement MANDT
1 S012 EKORG T024E Purchasing Organizations EKORG
0 S012 HWAER TCURC Currency Codes MANDT
0 S012 HWAER TCURC Currency Codes WAERS
1 S012 INFNR EINA Purchasing Info Record: General Data INFNR
0 S012 LAND1 T005 Countries MANDT
0 S012 LAND1 T005 Countries LAND1
1 S012 LIFNR LFA1 Supplier Master (General Section) MANDT
1 S012 LIFNR LFA1 Supplier Master (General Section) LIFNR
0 S012 MATKL T023 Material Groups MATKL
1 S012 MATNR MARA General Material Data MANDT
1 S012 MATNR MARA General Material Data MATNR
0 S012 WERKS T001W Plants/Branches WERKS