Top Banner
1/5/2016 Appendix A: Description of the SAPDelivered Tables Used in the HandsOn Exercises SAP ABAP: HandsOn Test Projects with Business Scenarios https://www.safaribooksonline.com/library/view/sapabaphandson/9781430248040/9781430248033_AppA.xhtml 1/7 APPENDIX A Description of the SAPDelivered Tables Used in the HandsOn Exercises SAPDelivered Tables Used in the HandsOn Exercises of the Book – Categories and Subcategories This appendix contains descriptions of SAPdelivered tables, which you will use in the handson exercises of the book. Using an SAPdelivered table means that (i) some feature of the table is being highlighted in the book; (ii) the table is being used in the creation of ABAP dictionary objects such as views or search helps, etc., as part of handson exercise/s; and (iii) the table is used to access data in handson exercises on ABAP program/s (SELECT…). You will relate better to the SAPdelivered table descriptions in this appendix after studying the two chapters on the ABAP dictionary Chapters 2 and 3 . The phrase “SAP delivered” is being dropped from the subsequent text in the appendix because it is implicit. The tables described in this appendix are SAPdelivered tables only. You will be using the following categories and subcategories of tables: The “T” series tables. The table names start with the letter “T.” The “T” series tables contain: 1. Universal nature of data such as country codes, country texts, currency codes, currency texts, etc. When SAP is installed, these tables are automatically populated with the universal data. 2. Configuring data. In a reallife scenario, the configuring data tables get populated when configurations are performed by functional consultants. A simple example of configuring a table is the table T001 storing company codes. When company codes are created, typically by a finance functional module consultant, the table T001 gets populated. The “T” series tables containing universal data or configuring data are client dependent. That is, the first field in these tables is of DDIC data type CLNT. 3. There are tables whose names start with the letter “T,” containing other than universal or configuring information. These tables are cross client or client independent. An example of this table subcategory: TRDIRT storing ABAP source program title. The master data tables: These tables contain customer, vendor, material, and other information. Each of the master data information resides mostly in multiple tables. The customer, vendor, and material tables contain many fields; you will confine yourself to using a few essential fields. The master data tables are client dependent. That is, the first field in these tables is of DDIC data type CLNT. The transaction data tables: The transaction data tables contain business document information. You will use these in most hands on exercises in the four business document tables relating to PREV Chapter 14: Screen Programming NEXT Index SAP ABAP: Hands-On Test Projects with Business Scenarios Recent Topics Highlights Settings Feedback Sign Out Settings 10 days left in your trial. Subscribe. Feedback Sign Out Tutorials Enjoy Safari? Subscribe Today
7

Appendix a description of the sap delivered tables used in the hands-on exercises - sap abap- hands-on test projects with business scenarios

Jan 22, 2018

Download

Software

Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Appendix a  description of the sap delivered tables used in the hands-on exercises - sap abap- hands-on test projects with business scenarios

1/5/2016 Appendix A: Description of the SAP­Delivered Tables Used in the Hands­On Exercises ­ SAP ABAP: Hands­On Test Projects with Business Scenarios

https://www.safaribooksonline.com/library/view/sap­abap­hands­on/9781430248040/9781430248033_AppA.xhtml 1/7

APPENDIX A

Description of the SAP­Delivered Tables Used in the Hands­OnExercises

SAP­Delivered Tables Used in the Hands­On Exercises of theBook – Categories and Subcategories

This appendix contains descriptions of SAP­delivered tables, which you

will use in the hands­on exercises of the book. Using an SAP­delivered

table means that (i) some feature of the table is being highlighted in the

book; (ii) the table is being used in the creation of ABAP dictionary

objects such as views or search helps, etc., as part of hands­on exercise/s;

and (iii) the table is used to access data in hands­on exercises on ABAP

program/s (SELECT…).

You will relate better to the SAP­delivered table descriptions in this

appendix after studying the two chapters on the ABAP dictionary —

Chapters 2 and 3 .

The phrase “SAP delivered” is being dropped from the subsequent text in

the appendix because it is implicit. The tables described in this appendix

are SAP­delivered tables only.

You will be using the following categories and subcategories of tables:

The “T” series tables. The table names start with the letter “T.” The

“T” series tables contain:

1. Universal nature of data such as country codes, country texts,

currency codes, currency texts, etc. When SAP is installed,

these tables are automatically populated with the universal

data.

2. Configuring data. In a real­life scenario, the configuring

data tables get populated when configurations are performed

by functional consultants. A simple example of configuring a

table is the table T001 storing company codes. When

company codes are created, typically by a finance functional

module consultant, the table T001 gets populated.

The “T” series tables containing universal data or

configuring data are client dependent. That is, the first field

in these tables is of DDIC data type CLNT.

3. There are tables whose names start with the letter “T,”

containing other than universal or configuring information.

These tables are cross client or client independent. An

example of this table subcategory: TRDIRT storing ABAP

source program title.

The master data tables: These tables contain customer, vendor,

material, and other information. Each of the master data

information resides mostly in multiple tables. The customer,

vendor, and material tables contain many fields; you will confine

yourself to using a few essential fields.

The master data tables are client dependent. That is, the first field in

these tables is of DDIC data type CLNT.

The transaction data tables: The transaction data tables contain

business document information. You will use these in most hands­

on exercises — in the four business document tables relating to

PREVChapter 14: Screen Programming

NEXTIndex

SAP ABAP: Hands-On Test Projects with Business Scenarios Recent

Topics

Highlights

Settings

Feedback

Sign Out

Settings

10 days left in your trial. Subscribe.

Feedback

Sign Out

Tutorials

Enjoy Safari? Subscribe Today

Page 2: Appendix a  description of the sap delivered tables used in the hands-on exercises - sap abap- hands-on test projects with business scenarios

1/5/2016 Appendix A: Description of the SAP­Delivered Tables Used in the Hands­On Exercises ­ SAP ABAP: Hands­On Test Projects with Business Scenarios

https://www.safaribooksonline.com/library/view/sap­abap­hands­on/9781430248040/9781430248033_AppA.xhtml 2/7

sales. You will use, for the most part, the tables related to billing.

Only once will you will use tables related to the sales document

(sales order). The transaction data tables also contain many fields;

however, you will be confined to using a few essential ones.

The transaction data information of each business document is typically

stored in two tables: the header table containing the header information

and the item table containing item information.

The transaction data tables are also client dependent. That is, the first

field in these tables is of DDIC data type CLNT.

Cross client (client independent) tables. Examples of this table

subcategory: DD02L storing table names, DD03l storing table field

names, etc.

The master data and transaction data table categories are mentioned in

any business application software context. The other categories and

subcategories (“T” series and cross client, etc.) are specific to our present

context and only for making the present context of table descriptions

clearer. A diagrammatic representation of the categories and

subcategories of tables used in the hands­on exercises of the book is

shown in Figure A­1:

Figure A­1. Tables used in hands­on exercises ­ categories andsubcategories

The table subcategories are numbered as I, II … IX in Figure A­1.

One of the tables BUT000_TD does not fit into any of the neatly defined

nine subcategories!

Out of the very large number of tables in the SAP application, very few –

29 – are being used in the hands­on exercises of the book.

If you are logged into the SAP IDES server, it is already configured for

multiple dummy company codes and contains substantial dummy data in

the configuring, master data, and transaction data tables. The IDES

server is ideal to perform the hands­on exercises of the book. The hands­

on exercises in the book produced results using the IDES server.

When describing tables, the fields are marked as PK for primary key

fields and FK for foreign key fields.

The table descriptions follow:

“T” Series ­ Universal Data Tables

Table A­1. T005T (Country names)

Table A­2. T005U (Taxes: Region key texts)

Table A­3. TCURT (Currency code names)

“T” Series ­ Configuring Data Tables

Note For brevity, other fields of this table are not mentioned.

Table A­4. T000 (Clients installed on the system)

Note For brevity, other fields in this table are not mentioned.

Page 3: Appendix a  description of the sap delivered tables used in the hands-on exercises - sap abap- hands-on test projects with business scenarios

1/5/2016 Appendix A: Description of the SAP­Delivered Tables Used in the Hands­On Exercises ­ SAP ABAP: Hands­On Test Projects with Business Scenarios

https://www.safaribooksonline.com/library/view/sap­abap­hands­on/9781430248040/9781430248033_AppA.xhtml 3/7

Table A­5. T001 (Company codes)

A company code – BUKRS ­ is associated with a country, currency, and

language.

Table A­6. TVKO (Organization unit: Sales organizations)

Table A­7. TVKOT (Organization unit: Sales organization texts)

Table A­8. TVTW (Organization unit: Distribution channels)

Table A­9. TVTWT (Organization unit: Distribution channel texts)

Table A­10. TSPA (Organization unit: Sales divisions)

Table A­11. TSPAT (Organization unit: Sales division texts)

‘T’ Series ­ Cross Client Tables

Table A­12. TRDIRT (Title texts for programs in TRDIR)

Table A­13. T247 (Month name and short text)

Master Data Tables ­ Customers

Table A­14. KNA1 (General data in customer master)

Table A­15. KNB1 (Customer master ­ company code)

Table A­16. KNVV (Customer master sales data)

Page 4: Appendix a  description of the sap delivered tables used in the hands-on exercises - sap abap- hands-on test projects with business scenarios

1/5/2016 Appendix A: Description of the SAP­Delivered Tables Used in the Hands­On Exercises ­ SAP ABAP: Hands­On Test Projects with Business Scenarios

https://www.safaribooksonline.com/library/view/sap­abap­hands­on/9781430248040/9781430248033_AppA.xhtml 4/7

Master Data Tables ­ Vendors

Table A­17. LFA1 (Vendor master – general section)

Table A­18. LFB1 (Vendor master ­ company code)

Master Data Tables – Material

Table A­19. MAKT (Material descriptions)

Material descriptions or texts (field MAKTX) are maintained in multiple

languages.

The material master table is MARA. The hands­on exercises in this book

are not using any fields of this table. Hence, for simplicity and

expediency, the table MARA is being bypassed. Normally, you will access

material description table MAKT through the material master table

MARA.

Transaction Data Tables ­ Sales

Table A­20. VBAK (Sales document: Header data)

Table A­21. VBAP (Sales document: Item data)

Table A­22. VBRK (Billing document: Header data)

The table VBRK is linked to the header status and administrative data

table VBUK. For this reason the field VBELN is marked as FK or foreign

key. For simplicity and expediency, this relationship is being ignored.

The table VBUK is not featuring in the sales functionality ER diagram in

Figure A­2.

Fields Requiring Further Explanation

Page 5: Appendix a  description of the sap delivered tables used in the hands-on exercises - sap abap- hands-on test projects with business scenarios

1/5/2016 Appendix A: Description of the SAP­Delivered Tables Used in the Hands­On Exercises ­ SAP ABAP: Hands­On Test Projects with Business Scenarios

https://www.safaribooksonline.com/library/view/sap­abap­hands­on/9781430248040/9781430248033_AppA.xhtml 5/7

WAERK

A billing document can be generated in any currency. This field contains

the currency code of the billing document.

KUNAG

The field KUNAG is a categorization of the customer. In an enterprise,

you will ship the material to a particular customer authority and address;

send the billing document to a different customer authority and address.

Authority in an enterprise is distributed. For your purposes, you can treat

the field KUNNR in tables KNA1, KNB1, and the field KUNAG in table

VBRK as equivalent.

NETWR

This field contains the amount for all the items of a billing document. A

billing document can contain zero or n number of items.

Each billing document amount value can be of a different currency. The

billing document amount values can be converted to a single currency,

the currency of the company code by multiplying the field NETWR with

the exchange rate field KURRF.

The field NETWR can contain negative values. The following scenario

will elucidate why a billing document can contain a negative value.

Suppose an enterprise sells 1,000 bolts at $ 1 apiece to a customer. The

1,000 bolts are dispatched to the customer along with a billing document

of value $ 1,000. This billing document is categorized as a bill or an

invoice. At the customer site, it is discovered that 5 bolts are defective or

broken or short. In this situation, the customer must be charged only for

995 bolts. The typical accounting procedure that is followed to ensure that

the customer is charged for 995 bolts only does not involve cancellation

of the original billing document of $ 1,000 and reissuing of a new billing

document of $ 995. A document category Credit Memo is generated with

an amount value of $ ­5. The net of these two billing documents will

charge the customer $995. Since credit is to be given to the customer for $

5, the document category is called a Credit Memo. You can have a

scenario of customer receiving excess of quantity over the billing

document say 1005 bolts. Then the customer needs to be charged for the

extra 5 bolts. The extra charge of 5 bolts worth $ 5 will be adjusted

through another document category: the Debit Memo.

To take care of minor adjustments to a generated billing document such

as described in the previous paragraph, a debit or a credit memo is

generated. Consider a scenario where all the dispatched goods get

damaged during transportation. In such a situation, a complete

cancellation of the invoice/bill is warranted. This kind of major

adjustment is taken care by a document category Invoice cancellation.

The document category (called the SD document category) is stored in the

field VBTYP. Look up Value Range tab of the domain VBTYP for viewing

all the SD document categories.

While accumulating the converted values of the field NETWR to obtain

total sales of customers, materials, etc., it is to be ensured that only the

document categories that contribute to the actual sales are retrieved.

(WHERE VBTYP = … etc.) Document categories such as Performa Invoice

do not generate actual sales. Such document categories should be omitted

when accumulating sales for customers, materials, etc. This has not been

done in the hands­on exercises in the book. In the training and teaching

paradigm, this can be overlooked, but you must still be aware of this

issue.

Since the billing tables can contain not just the invoices/bills but multiple

document categories, the tables are called billing document tables.

Table A­23. VBRP (Billing document: Item data)

The table VBRP is not directly linked to the table VBRK. The table VBRP

linked to the table VBRK through the header status and administrative

data table VBUK. You can check this out by opening the foreign key dialog

box for the field VBELN of table VBRP. For simplicity and expediency,

the two tables VBRK and VBRP are linked directly for the hands­on

exercises in the book. The sales functionality ER diagram in Figure A­2

reflects the direct linkage.

Fields Requiring Further Explanation

VRKME

sales unit of measure. For the same material, different units of measure

can be used in different situations. A simple example: an enterprise may

purchase a material in dozens and sell the same material innumbers/units.

NETWR

Page 6: Appendix a  description of the sap delivered tables used in the hands-on exercises - sap abap- hands-on test projects with business scenarios

1/5/2016 Appendix A: Description of the SAP­Delivered Tables Used in the Hands­On Exercises ­ SAP ABAP: Hands­On Test Projects with Business Scenarios

https://www.safaribooksonline.com/library/view/sap­abap­hands­on/9781430248040/9781430248033_AppA.xhtml 6/7

If you want to accumulate sales material wise, you will use the field

NETWR of this table – that is, VBRP: multiply it with the corresponding

exchange rate field KURRF of the table VBRK. For a billing document,

you might end up with the total of individual amounts (NETWR) from the

table VBRP multiplied by the exchange rate not exactly equal to that of

the field NETWR of table VBRK multiplied by the exchange rate. There

could be a slight difference between the two.

Tables of Sales Functionality ­ ER Diagram

An ER diagram of tables of sales functionality used in the hands­on

exercises in the book is shown in Figure A­2:

Figure A­2. Sales functionality tables ­ ER diagram

The ER diagram shown in Figure A­2 is not a comprehensive ER diagram

as such, depicts and shows only the table relationships used in the hands­

on exercises in the book.

Contextual ER diagrams are available in the chapters.

Transaction Data Tables ­ Purchase

For most programming hands­on exercises in the book, we have used the

tables from the sales functionality. If you want to perform independently

programming hands­on exercises on a parallel basis, you can use the

tables from the purchase functionality.

While using the tables from the purchase functionality, you must bear in

mind the following:

The purchasing document tables contain data for different

categories of purchasing documents such as purchase orders (POs)

and request for quotation (RFQs), etc. This is similar to the billing

documents tables containing different categories of billing

documents such as invoices/bills, credit memos, debit memos, etc.

You are summing the NETWR converted values for the different

categories of billing documents. This made sense as described in

the scenario of field NETWR of table VBRK. With the purchasing

document tables, it does not make sense to sum converted amounts

of different categories of purchasing documents such as purchaseorders, request for quotation, etc. So while retrieving data from the

purchasing document table; filter out the purchase orders data from

the header table. The purchasing document category is contained

in the field BSTYP. Refer to the Single Values tab of domain of this

name for values of categories for purchasing documents.

Unlike in the billing document tables, the total amount for a

document is not available in the purchasing document header

table. That is, the field NETWR is not available in the purchasing

document header table EKKO. This field is available only in the

purchasing document item table EKPO.

Table A­24. EKKO (Purchasing document header)

Table A­25. EKPO (Purchasing document item)

ER Diagram of Tables of Purchase Functionality

An ER diagram of tables of purchase functionality is shown in Figure A­3:

Figure A­3. Purchase functionality tables ­ ER diagram

The ER diagram shown in Figure A­3 is not a comprehensive ER diagram

as such; it depicts and shows only the table relationships to be used in the

independent hands­on exercises by the reader.

X. Cross client (Client independent) tables

A few non ­ ‘T’ series cross client (client independent) tables have been

used in hands­on exercises in the book. The description of these tables

follows:

Table A­26. ICON (Icons table)

Page 7: Appendix a  description of the sap delivered tables used in the hands-on exercises - sap abap- hands-on test projects with business scenarios

1/5/2016 Appendix A: Description of the SAP­Delivered Tables Used in the Hands­On Exercises ­ SAP ABAP: Hands­On Test Projects with Business Scenarios

https://www.safaribooksonline.com/library/view/sap­abap­hands­on/9781430248040/9781430248033_AppA.xhtml 7/7

Recommended / Queue / Recent / Topics / Tutorials / Settings / Blog / Feedback / Sign Out© 2016 Safari. Terms of Service / Privacy Policy

Table A­27. DD02L (SAP tables)

Table A­28. DD03L (Table fields)

Non­categorized Table

The client dependent table BUT000_TD does not fit into any of our

subcategories. This table was introduced in Chapter 2 to highlight in the

foreign key field dialog box, the column generic key field. That is all. This

table has not been referred to or used in any other place in the book. The

table’s fields are not listed since this table is not being processed in any

of the hands­on exercises in the book.

Conclusion

This appendix was a description of all the tables used in the hands­on

exercises in the book. Instead of using hypothetical tables, real­life

application tables have been used to perform the hands­on exercises. The

table descriptions give you technical as well as functional insights. And

they also give you a fair perspective of the complexities of the real­life

SAP application tables.

PREVChapter 14: Screen Programming

NEXTIndex