*&---------------------------------------------------------------------* *& Report Z_CPT3_4 * *& * *&---------------------------------------------------------------------* *& 简介:自定义类型,结构体,指针,表类型,内表 *& * *&---------------------------------------------------------------------* REPORT Z_CPT3_4 . TYPES: FirstName(10) TYPE c, LastName(10) TYPE c, BirthDay TYPE d, Age(3) TYPE n, Tall TYPE f, Salary TYPE p DECIMALS 2, BEGIN OF EMPLOYEE, FirstName TYPE FirstName, LastName TYPE LastName, BirthDay TYPE BirthDay, Age TYPE Age, Salary TYPE Salary, END OF EMPLOYEE. DATA:first TYPE FirstName, last TYPE LastName, birth TYPE BirthDay, age TYPE Age, tall TYPE Tall, salary TYPE Salary. first = 'jim'. last = 'green'. birth = '19870103'. age = '25'. tall = '170.5'. salary = '8000.1234'. WRITE: / 'FirstName:', first, / 'LastName:', last, / 'BirthDay:', birth, / 'Age:', age, / 'Tall:',tall, / 'Salary:',salary. SKIP 3. WRITE:'The other information:'. DATA:jim TYPE EMPLOYEE. jim-FirstName = 'jim'. jim-LastName = 'green'. jim-Age = '21'. jim-BirthDay = '19870103'. jim-Salary = '10000'. WRITE: / 'FullName:',jim-FirstName, / 'Age:',jim-Age, / 'BirthDay:',jim-BirthDay, / 'Salary:',jim-Salary. *指针 DATA myPoint TYPE REF TO EMPLOYEE. *CREATE myPoint.