Sunday

ABAP System Fields

ABAP System Fields.

ABCDE Constant: Alphabet (A,B,C,...)

APPLI SAP applications

BATCH Background active (X)

IF SY-BATCH EQ SPACE.

WRITE: / 'Report was started on-line'.

WRITE: / 'Using variant:', SY-SLSET.

ELSE.

WRITE: / 'Report was started in background'.

ENDIF.

BATZDBackground SUBMIT: Daily

BATZMBackground SUBMIT: Monthly

BATZOBackground SUBMIT: Once

BATZSBackground SUBMIT: Immediately

BATZW Background SUBMIT: Weekly

BINPTBatch input active (X)

This field indicates if the transaction was called in a Batch Input session or by an online user. To test it, a batch input session must be created. From Release 3.1g the next procedure can be used.

o Create a report which displays this system field
o Create a Transaction code for this report
o Use transaction SHDB to record a the previous transaction
o Press the Overview button and choose the 'generate program' function.
o Running the previously generated program it will create a Batch Input
session
o Now call transaction SM35 and process the created Batch Input in
foreground. It should display an 'X' for system field SY-BINPT.

BREP4Background SUBMIT: Root name of request report

BSPLDBackground SUBMIT: List output to spool

CALLDCALL mode active (X)

This field indicates if the transaction was called from another transaction.

o Create a report which displays this system field
o Create a Transaction code for this report
o Create a new report containing the next ABAP command: CALL TRANSACTION tcode. Where tcode is the Transaction code you created. When you run this report, it should display an 'X' for system field SY-CALLD.

CALLR Print: ID for print dialog function

CCURS Rate specification/result field (CURRENCY CONVERT)

CCURTTable rate from currency conversion

CDATEDate of rate from currency conversion

COLNOCurrent column during list creation

WRITE: SY-COLNO, ',', SY-LINNO, 'Cursor position (column, row).'.

CPAGECurrent page number

WRITE: / 'SY-CPAGE:', SY-CPAGE LEFT-JUSTIFIED.

CPROG
Runtime: Main program
WRITE: /5 'Main program:' RIGHT-JUSTIFIED, 40 SY-CPROG.

CTABLExchange rate table from currency conversion

CTYPE
Exchange rate type 'M','B','G' from CURRENCY CONVERSION

CUCOLCursor position (column)

WRITE: / 'SY-CUCOL:', SY-CUCOL LEFT-JUSTIFIED.

CUROWCursor position (line)

WRITE: / 'SY-CUROW:', SY-CUROW LEFT-JUSTIFIED.

DATARFlag: Data received

In transaction programming this field indicates the change of data on the screen. In the PBO part you may set default values of the input fields of the dynpro. In the PAI part you can check if they were changed. If SY-DATAR is set, then the user has modified or entered new data on the screen.

DATLOLocal date for user

DATUMSystem: Date

DATUTGlobal date related to UTC (GMT)

DAYSTSummertime active ? ('daylight saving time')

DBCNT Number of elements in edited dataset with DB operations
WRITE: /12 'Number of selected records:', SY-DBCNT CENTERED.

DBNAMLogical database for ABAP/4 program

DBSYS System: Database system

DCSYS System: Dialog system

DSNAMRuntime: Name of dataset for spool output

DYNGRScreen group of current screen

DYNNRNumber of current screen

FDAYWFactory calendar weekday

FDPOSLocation of a string

SEARCH T FOR 're'.

READ TABLE T INDEX SY-TABIX.

WRITE: / SY-TABIX, T-FIELD.

SKIP.

WRITE: /9 'At the example of sy-tabix, Row', (3) SY-TABIX, ',' ,

'keyword ''re'' found at off-set position:', (3) SY-FDPOS.

FMKEY Current function code menu

HOST Host

INDEX
Number of loop passes

DO 5 TIMES.

WRITE: SY-INDEX.

ENDDO.

LANGUSAP logon language key

LDBPGProgram: ABAP/4 database program for SY-DBNAM

LILLI Number of current list line

AT LINE-SELECTION.

DETAIL.
* SY-LSIND is the index of the current list
WRITE: / 'SY-LSIND:', SY-LSIND LEFT-JUSTIFIED.
* SY-LISTI is the index of the previous list
WRITE: / 'SY-LISTI:', SY-LISTI LEFT-JUSTIFIED.
* SY-LILLI is the number of the selected line in the absolute list
WRITE: / 'SY-LILLI:', SY-LILLI LEFT-JUSTIFIED.

LINCT Number of list lines

WRITE: / SY-LINCT, 'line and', (3) SY-LINSZ, 'column is a page'.

LINNOCurrent line for list creation

WRITE: SY-COLNO, ',', SY-LINNO, 'Cursor position (column, row).'.

LINSZ Line size of list

WRITE: SY-COLNO, ',', SY-LINNO, 'Cursor position (column, row).'.

LISELInteract.: Selected line

* contents of the selected line

WRITE: / 'SY-LISEL:', SY-LISEL.

LISTINumber of current list line

* SY-LISTI is the index of the previous list

WRITE: / 'SY-LISTI:', SY-LISTI LEFT-JUSTIFIED.

LOCDB Local database exists

LOCOPLocal database operation

LOOPCNumber of LOOP lines at screen step loop

LSINDNumber of secondary list

* SY-LSIND is the index of the current list

WRITE: / 'SY-LSIND:', SY-LSIND LEFT-JUSTIFIED.

LSTATInteract.: Status information for each list level

MACDBProgram: Name of file for matchcode access

MACOLNumber of columns from SET MARGIN

MANDTClient number from SAP logon

MARKYCurrent line character for MARK

MAROWNo. of lines from SET MARGIN statement

MODNO Number of alternative modi

MSGIDMessage ID

MSGLI Interact.: Message line (line 23)

MSGNOMessage number

MSGTYMessage type (E,I.W,...)

MSGV1Message variable

MSGV2Message variable

MSGV3Message variable

MSGV4Message variable

OPSYSSystem: Operating system

PAARTPrint: Format

PAGCTPage size of list from REPORT statement

PAGNORuntime: Current page in list

PDESTPrint: Output device

PEXPIPrint: Spool retention period

PFKEYRuntime: Current F key status

PLISTPrint: Name of spool request (list name)

PRABTPrint: Department on cover sheet

PRBIGPrint: Selection cover sheet

PRCOPPrint: Number of copies

PRDSNPrint: Name of spool dataset

PREFXABAP/4 prefix for background jobs

PRIMMPrint: Print immediately

PRNEWPrint: New spool request (list)

PRRECPrint: Recipient

PRRELPrint: Delete after printing

PRTXTPrint: Text for cover sheet

REPIDProgram: Name of ABAP/4 program

RTITLPrint: Report title of program to be printed

SAPRLSystem: SAP Release

SCOLSColumns on screen

SLSETName of selection set

SPONORuntime: Spool number for list output

SPONRRuntime: Spool number from TRANSFER statement

SROWSLines on screen

STACOInteract.: List displayed from column

STAROInteract.: Page displayed from line

STEPLNumber of LOOP line at screen step

SUBRCReturn value after specific ABAP/4 statements

SUBTYABAP/4: Call type for SUBMIT

SYSIDSystem: SAP System ID

TABIXRuntime: Current line of an internal table

SEARCH T FOR 're'.

READ TABLE T INDEX SY-TABIX.

TCODESession: Current transaction code

TFDSNRuntime: Dataset for data extracts

TFILLCurrent number of entries in internal table

TIMLOLocal time for user

TIMUTGlobal time related to UTC (GMT)

TITLETitle of ABAP/4 program

TLENGLine width of an internal table

TMAXLMaximum number of entries in internal table (?)

TNAMEName of internal table after an access (?)

TOCCUOCCURS parameter with internal tables

TPAGIFlag indicating roll-out of internal table to paging area (?)

TSTLOTimestamp (date and time) for user

TSTUTTimestamp (date and time) related to UTC (GMT)

TTABCNumber of line last read in an internal table (?)

TTABIOffset of internal table in roll area (?)

TVAR0Runtime: Text variable for ABAP/4 text elements

TVAR1Runtime: Text variable for ABAP/4 text elements

TVAR2 Runtime: Text variable for ABAP/4 text elements

TVAR3Runtime: Text variable for ABAP/4 text elements

TVAR4Runtime: Text variable for ABAP/4 text elements

TVAR5Runtime: Text variable for ABAP/4 text elements

TVAR6Runtime: Text variable for ABAP/4 text elements

TVAR7Runtime: Text variable for ABAP/4 text elements

TVAR8Runtime: Text variable for ABAP/4 text elements

TVAR9Runtime: Text variable for ABAP/4 text elements

TZONETime difference from 'Greenwich Mean Time' (UTC) in seconds

UCOMMInteract.: Command field function entry

ULINEConstant: Underline (---------...)

UNAMESession: SAP user from SAP logon

UZEITSystem: Time

VLINEConstant: Vertical bar

WAERST001: Company code currency after reading B segment

WILLINumber of current window line

WINCOCursor position in window (column)

WINDIIndex of current window line

WINROCursor position in window (line)

WINSLInteract.: Selected window line

WINX1Window coordinate (column left)

WINX2Window coordinate (column right)

WINY1Window coordinate (line left)

WINY2Window coordinate (line right)

WTITLStandard page header indicator

XCODEExtended command field

ZONLOTime zone of user

SAP R/3 ABAP Architecture

Before moving further it is essential to know the Architectur of SAP /3. You will find here excellent architechtural view in short.

SAP R/3 ABAP Architecture (Logical View ):-


SAP R/3 ABAP Architecture ( Software View ):-


SAP R/3 ABAP Application Server Architecture :-


In short:
Application server also knows as ‘Instance’, Database Server known as ‘Central Instance’.
The architecture of application server defines as:
All the requests that come from the presentation servers are directed first to the dispatcher. The dispatcher writes them fist to the dispatcher queue. Te dispatcher pulls the request from the queue on first-in , first-out basis. Each request is then allocated to the first available work process.

To perform any processing for a user’s request a work process needs to address two special memory areas i.e. User Context and the program roll area. The user context is a memory area that contains information about the user and the roll area is a memory area that contains information about the user, and the roll area is a memory area that contains information about the program execution.

User Context is responsible for:
- User’s Current settings
- User Authorizations
- The name of the program the user currently is running

Roll Area is responsible for:
- The values of the variables
- The dynamic memory allocations
- The current program pointer

Each time a user starts a program, a roll area is created for that instance of the program. If two users run the same program at the same time, two roll areas will exist-one for each user. The roll area is freed when the program ends.

Roll Area and the user context play an important part in dialog step processing.

Roll-In / Roll-out processing in dialog step process. An ABAP/4 program only occupies a work process for one dialog step. At the beginning of the dialog step, the roll area and user context are rolled into the work process. At the end of the dialog step they rolled out.
During the roll in pointers to the roll area and user context are populated in the work process. This enables the work process to access the data in those areas and so perform processing for that user and that program. Processing continues until the program sends a screen to the user. At that time, both areas are rolled out. Roll-out invalidates the pointers and disassociates these areas from the work process. That work process is now free to perform processing for other requests. The program is now only occupying memory, and not consuming any CPU. The user is looking at the screen that was sent, and will soon send another request.

Components of work process:
Each work process composed of:
- A Task Handler
- An ABAP Interpreter
- A screen Interpreter
- A Database Interface
All requests pass through the task handler, which then funnels the request to the appropriate part of the work process.
The interpreters interpret the ABAP/4 code. Notice that there are two interpreters: the ABAP/4 interpreter and the screen interpreter. There are actually two dialects of ABAP/4. One is the full-blown ABAP/4 data processing language and the other is a very specialized screen processing language. Each is processed by its own interpreter. The database interface handles the job of communicating with the database.

There are seven types of work process each handles a separate type of requests.
WP Type Request Type
D (Dialog) Dialog requests
V (Update) Requests to update data in the database
B (Background) Background jobs
S (Spool) Print spool requests
E (Enqueue) Logical lock requests
M (Message) Routes messages between application servers within an R/3 system
G (Gateway) Funnels messages into and out of the R/3 system

Memory Structures of an ABAP Program
A user can open up to six R/3 windows in a single SAPgui session. Each of these windows corresponds to a session on the application sever with its own area of shared memory.
The first application program that you start in a session opens an internal session within the main session. The internal session has a memory area that contains the ABAP program and its associated data. When the program call external routines (methods, subroutines or functional module) in their main program and working data are also loaded in to the memory area of the internal session.



Only one internal session is ever active. If the application program calls a further application program the system opens another internal session. Here there are two possible cases: If the second program does not return control to the calling program when it has finished running, the called program replaces the calling program in the internal session. The Contents of the memory of the calling program are deleted. If the second program does return control to the calling program when it has finished running the session of the called program is not deleted. Instead it becomes inactive and its memory contents are placed on a stack.

The memory area of each session contains an area called ABAP memory. ABAP memory is available to all internal sessions.

All ABAP programs can also access the SAP memory. This is the area to which all sessions within a SAPGUI have access. One can use SAP memory either to pass data from one program to another within a session or to pass data from one session to another.
Application programs that use SAP memory must do so using SAP/GAP parameters (also known as SET/Get parameters).
SAP memory is the only connection between the different sessions within a SAPgui.

ABAP Work Bench

The ABAP/4 language is the central tool in the excellent development package called ABAP/4 Development Workbench.

ABAP/4 Development Workbench proves its strength in R/3 system itself where more then thousand developers used the workbench tools to build an Integrated Packages of business Application.

Development WorkBench is made up of the following tools.

1. Object Browser
2. ABAP/4 Language
3. Repository Includes the Active Directoy.
4. Data Modeler
5. The Query
6. workBench Organiser
7. Various Test & Analysis Tools

ABAP/4 Repository

Repository Conatins all the development objects .

1. Data Models
2. Programs
3. Dictionary Types & Tables Structures
4. System wide Reusable Functions
5. Screens
6. GUI statuses with meny functions and Icons
7. Language dependent texts such as help info, documetation and error messages
8. Report Variants
9. ABAP/4 Queries

Transaction Codes related to ABAP Workbench
- "S001" ABAP Development WorkBench
- "SE09" WorkBench Organiser
- "SE80" ABAP/4 Development WorkBench

What is SAP R/3?

R/3 is an integrrated suit of applications designed to handled the data processing for large corporations. R/3 is Developed by SAP (System Applications and Products in Data Processing ) a german based company.

Within R/3 (Real Time Three Tier Architechture) is a runtime environment and an integrated suit of application programs writte in SAP's 4-GL, ABAP/4. R/3 Intergrated programs are designed to meet the data processing need of very large business.

Standard set of Application in R/3 also called R/3 fnction areas are :

.PP Production Planning
.MM Material Management
.SD Sales & Distribution
.FI Financial Accounting
.CO Controlling
.AM Fixed asset Management
.PS Project System
.WF Workflow
.IS Industry Solutions
.HR Human Resources
.PM Plant Maintenance
.QM Quality Management


R/3 system divided into three conceptual areas:

1. Appication Area
2. Basis Area
3. Development Workbench

In application area you initiate transaction for the functional area within R/3 i.e. Logistics, Accounting, Human Resources, or Information Systems.

The Basis area, you can run transactions that monitor the R/3 system itself.

Development Workbench is used to create and test ABAP/4 programs. As an ABAP/4 programmer, you will spend most of your time within the Workbench.

SAP R/3 Releases since 1998

- SAP R/3 Release 4.0B Release Date June 1998
- SAP R/3 Release 4.5B Release Date March 1999
- SAP R/3 Release 4.6B Release Date Dec 1999
- SAP R/3 Release 4.6C Release Date April 2001
- SAP R/3 Enterprise Release 4.70 Release Date March- Dec 2003

SAP ABAP TRANSACTION CODES

Transaction is a dialog program that changes objects in the database in a consistent way. ABAP/4 provides various transaction codes

ABAPDCOU ABAP Documentation

AL02 Database Alert Monitor

AL03 Operating System Alert Monitor

AL05 Workload Alert Monitor

AL08 Current active users (in system)

AL11 Display operating system file from CCMS

DB01 Exclusive waits in Oracle database

DB02 Database performance; tables and index

DB03 Parameter changes in database

DB05 Analysis of table with respect to indexed fields

DB12 Backup logs

DB13 DBA planning calendar

DB14 DBA logs

DI02 ABAP/4 Repository Information System: Tables.

OSS1 SAP Online Service System

OY19 Compare Tables

RZ01 Graphical background job scheduling monitor

RZ02 Network graphical display of instance

RZ03 Server status, alerts, maintain operations mode

RZ04 Maintain operations mode and instance

RZ06 Maintain alert threshold

RZ08 CCMS Alert Monitor

RZ10 Maintain system profiles X

RZ11 Display profile parameter attributes

RZ20 Alert Monitor 4.0

RZ21 Maintain settings for Alert Monitor 4.0

SM13 Update monitor. Will show update tasks status. Very useful to determine why an update failed.

S001 ABAP Development Workbench

S001 ABAP/4 Development Weorkbench.

S002 System Administration.

SA38 Execute a program.

SA38 ABAP reporting

SCAM CATT management

SCAT Computer Aided Test Tool

SCC1 Client copy transport X

SCC3 Client copy log

SCC4 Client copy administration X

SCC5 Delete clients X

SCC6 Client import X

SCC7 Client import – post processing

SCC8 Client export

SCC9 Remote client copy X

SCCL Local client copy X

SCMP Table comparison

SCU0 Compare Tables

SCU3 Table history

SD11 Data Modeler

SE01 Old Transport & Corrections screen

SE03 Groups together most of the tools that you need for doing transports. In total, more than 20 tools can be reached from this one transaction.

SE09 Workbench Organizer

SE10 New Transport & Correction screen

SE11 ABAP/4 Dictionary Maintenance SE12 ABAP/4 Dictionary Display SE13 Maintain Technical Settings (Tables)

SE12 Dictionary: Initial Screen - enter object name.

SE13 Access tables in ABAP/4 Dictionary.

SE14 Utilities for Dictionary Tables

SE15 ABAP/4 Repository Information System

SE16 Data Browser: Initial Screen.

SE16N Table Browser (the N stands for New, it replaces SE16). Provided by Smijo Mathew.

SE17 General Table Display

SE24 Class Builder

SE30 ABAP/4 Runtime Analysis

SE32 ABAP/4 Text Element Maintenance

SE35 ABAP/4 Dialog Modules

SE36 ABAP/4: Logical Databases

SE37 ABAP/4 Function Modules

SE38 ABAP Editor

SE39 Splitscreen Editor: Program Compare

SE41 Menu Painter

SE43 Maintain Area Menu

SE48 Show program call hierarchy. Very useful to see the overall structure of a program. Thanks to Isabelle Arickx for this tcode.

SE49 Table manipulation. Show what tables are behind a transaction code. Thanks to Isabelle Arickx for this tcode.

SE51 Screen Painter: Initial Screen.

SE54 Generate View Maintenance Module

SE61 R/3 Documentation

SE62 Industry utilities

SE63 Translation

SE64 Terminology

SE65 R/3 document. short text statistics SE66 R/3 Documentation Statistics (Test!)

SE68 Translation Administration

SE71 SAPscript layout set

SE71 SAPScript Layouts Create/Change

SE72 SAPscript styles

SE73 SAPscript font maintenance (revised)

SE74 SAPscript format conversion

SE75 SAPscript Settings

SE76 SAPscript Translation Layout Sets

SE77 SAPscript Translation Styles

SE80 ABAP/4 Development Workbench

SE81 SAP Application Hierarchy

SE82 Customer Application Hierarchy

SE83 Reuse Library. Provided by Smiho Mathew.

SE84 ABAP/4 Repository Information System

SE85 ABAP/4 Dictionary Information System

SE86 ABAP/4 Repository Information System

SE87 Data Modeler Information System

SE88 Development Coordination Info System

SE91 Maintain Messages

SE92 Maintain system log messages

SE93 Maintain Transaction

SE95 Modification Browser

SEU Object Browser

SFT2 Maintain public holiday calendar

SFT3 Maintain factory calendar

SHD0 Transaction variant maintenance

SICK Installation check

SM01 Lock transactions X

SM02 System messages

SM04 Overview of users

SM12 Lock table entries (unlock locked tables)

SM13 Update terminates X

SM21 View the system log, very useful when you get a short dump. Provides much more info than short dump

SM30 Maintain Table Views.

SM31 Table Maintenance

SM32 Table maintenance

SM35 View Batch Input Sessions

SM36 Schedule background jobs

SM37 View background jobs

SM39 Job analysis

SM49 External operating system commands, execute

SM50 Process Overview.

SM51 Delete jobs from system (BDC)

SM58 Error log for asynchronous RFC

SM59 RFC connection, maintain

SM62 Display/Maintain events in SAP, also use function BP_EVENT_RAISE

SM63 Operations mode, maintain

SM64 Event trigger

SM66 Global work process overview

SM69 External operating system commands, maintain

SMEN Display the menu path to get to a transaction

SMOD/CMOD Transactions for processing/editing/activating new customer enhancements.

SNRO Object browser for number range maintenance.

SP00 Spool

SP01 Spool control

SP02 Display output requests

SP11 TemSe (temporary sequential objects) contents

SP12 TemSe administration

SPAD Spool administration (printer setup)

SPAM SAP Patch Manager

SPAU Intersection SAP transport/customer modifications

SPCC Spool; consistency check

SPDD Intersection SAP transport/customer modifications, DDIC

SPIC Spool; installation check

SPRO Start SAP IMG (Implementation Guide).

SQ00 ABAP/4 Query: Start Queries

SQ01 ABAP/4 Query: Maintain Queries

SQ02 ABAP/4 Query: Maintain Funct. Areas

SQ03 ABAP/4 Query: Maintain User Groups
(Queries,Funct. Areas,User Groups are stored in table AQGQDOC and AQLQDOC )

SQ07 ABAP/4 Query: Language Comparison

ST01 SAP system trace X

ST02 Buffer statistics

ST03 Workload analysis

ST04 Database performance analysis

ST05 SQL trace X

ST06 Operating system monitor

ST07 Application monitor

ST08 Network monitor

ST09 Network Alert monitor

ST10 Table call statistics

ST11 Display developer trace X

ST12 Application monitor

ST14 Application analysis

ST22 ABAP dump analysis

ST4A Oracle: analyze the shared cursor cache

STAT Local transaction statistics

STMS Transport Management System X

STUN Performance monitoring

ST22 ABAP Dump analysis

SU01 User maintenance X

SU01D Display users

SU02 Maintain authorization profiles X

SU03 Maintain authorizations X

SU10 Mass change to user records X

SU12 Delete ALL Users X

SU2 Maintain user parameters

SU22 Authorization object check in transactions

SU3 Maintain own user parameters

SU53 Display authorization checked values

SU53 Display Authorization Values for User.

WEDI EDI Menu. IDOC and EDI base.

WE02 Display an IDOC

WE07 IDOC Statistics