Fields and Variables - Advanced Business Application Programming - Lecture Slides, Slides of Computer Programming

Computer applications are involved in running every business. This course teaches programming with respect to business. Key points in this lecture of Advanced Business Application Programming course are: Fields and Variables, Field Naming, Fields, Primary Data Types, Packed and Floating-Point Number, Arithmetic, Type Conversion, Type Coercion

Typology: Slides

2012/2013

Uploaded on 09/27/2013

vikrant
vikrant 🇮🇳

4.4

(9)

119 documents

1 / 13

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Introduction ABAP
Fields and Variables
docsity.com
pf3
pf4
pf5
pf8
pf9
pfa
pfd

Partial preview of the text

Download Fields and Variables - Advanced Business Application Programming - Lecture Slides and more Slides Computer Programming in PDF only on Docsity!

Introduction ABAP

Fields and Variables

Fields (Introduction)

 In ABAP, fields (or data objects) are named locations in memory  Variables store data that might change  Constants store data that does not change  As before, fields are declared with the DATA keyword

 KEEP IN MIND THAT ABAP IS A „BUSINESS‟

PROGRAMMING LANGUAGE

Fields (Characteristics)

 They nave a name  A defined length  And a data type  And possibly a length  And possibly an initial value

Fields (Primary Data Types)

Packed Numbers (Example)

DATA packed16 TYPE P LENGTH 7 DECIMALS 2. packed16 = '12121219.12'. WRITE packed16.

 Produces

LIKE

 Declare a variable having the dame data type as another variable  Makes it easier to change data types

DATA demo16instance1 LIKE packed16. DATA demo16instance2 LIKE packed16.

Arithmetic (Type Conversion)

 Looks like any other arithmetic expression (plus the space requirements)  SAP calls this compatible and convertible data types  Compatible types have the same data type, field type, …  Comparable types are converted using conversion rules (See handout)

Type Coercion (1)

 The following produces “1” because the result is rounded to an int

Numeric

Overflow

Outcome