GET DATASET: ABAP Keyword a Day
GET DATASET: Retrives the arrtibutes of the file.
GET DATASET [POSITIONS ] [ATTRIBUTE ].
Gets the attributes of a file opened using OPEN DATASET. The POSITIONS additions writes the current read/write position to the field <pos>. The ATTRIBUTE addition writes the attributes to a structure, <attr>, of the type DSET_ATTRIBUTES.
DATA: file TYPE string VALUE 'test.dat', pos TYPE I, text TYPE string. OPEN DATASET file FOR OUTPUT IN TEXT MODE ENCODING DEFAULT WITH SMART LINEFEED. TRANSFER '1234567890' TO file. GET DATASET file POSITION pos. TRANSFER 'ABCDEFGHIJ' TO file. CLOSE DATASET file. OPEN DATASET file FOR INPUT IN TEXT MODE ENCODING DEFAULT WITH SMART LINEFEED AT POSITION pos. READ DATASET file INTO text. CLOSE DATASET file.
If you like this post, you may as well like these too:
- AT : ABAP Keyword a day AT Events in lists- AT LINE-SELECTION.- AT USER-COMMAND.- AT PFn.Events on selection screens- AT SELECTION-SCREEN.Control break with extracts- AT NEW f.- AT END OF f.- AT FIRST.- AT LAST.- AT...
- GET: ABAP Keyword a day GET: Event keyword for defining event blocks for reporting events. GET <node> [FIELDS <fi> <f 2>...]. GET node LATE [FIELDS f1 f2 ...]. Only occurs in executable programs. When the...
- DO : ABAP Keyword a day DO Variants 1. DO. 2. DO n TIMES. Variant 1 DO. Addition … VARYING f FROM f1 NEXT f2 Effect Repeats the processing enclosed by the DO and ENDDO statements...
- ASSIGN: ABAP Keyword a day ASSIGN Variants:1. ASSIGN f TO .2. ASSIGN (f) TO .3. ASSIGN TABLE FIELD (f) TO .4. ASSIGN LOCAL COPY OF MAIN TABLE FIELD (f) TO .5. ASSIGN COMPONENT idx OF...
- FUNCTION: ABAP Keyword a Day FUNCTION : Defines a function module. FUNCTION <func_name> Introduces the function module . This statement is not entered in the ABAP Editor, but is automatically generated by the Function Builder...
- FIND: ABAP Keyword a Day FIND: Searches for patterns. FIND <p> IN [SECTION OFFSET <off> LENGTH <len> OF] <text> [IGNORING CASE| RESPECTING CASE] [IN BYTE MODE|IN CHARACTER MODE] [MATCH OFFSET <0>] [MATCH LENGTH <l>]. The...
- FETCH : ABAP Keyword a day FETCH Basic form FETCH NEXT CURSOR c target. Effect Uses the cursor c to read the next line or lines from the dataset of a database table determined by OPEN...
- ENDCASE : ABAP Keyword a day ENDCASE Basic form ENDCASE. Effect The ENDCASE statement closes a case disinction introduced by CASE ....
- DELETE : ABAP Keyword a day DELETE Delete from a database table - DELETE FROM dbtab WHERE condition. - DELETE FROM (dbtabname) WHERE condition. - DELETE dbtab. - DELETE *dbtab. - DELETE (dbtabname) … . -...
- CONTINUE: ABAP Keyword a day CONTINUE Basic formCONTINUE.EffectWithin loop structures like * DO … ENDDO* WHILE … ENDWHILE* LOOP … ENDLOOP* SELECT … ENDSELECTCONTINUE terminates the current loop pass, returns the processing to the beginning...
- CONCATENATE : ABAP Keyword a day CONCATENATE Basic form CONCATENATE f1 … fn INTO g. Addition … SEPARATED BY h Effect Places the fields f1 to fn after g . With the fields fi (1 <=...
- COMPUTE: ABAP Keyword a day COMPUTEBasic formCOMPUTE n = arithexp.EffectEvaluates the arithmetic expression arithexp and places the result in the field n .Allows use of the four basic calculation types + , – , *...
- CNT : ABAP Keyword a day CNT Basic form… CNT(h) …EffectCNT(h) is not a statement, but a field which is automatically created and filled by the system if f is a sub-field of an extract dataset...
- CASE: ABAP Keyword a day CASE Basic formCASE f. Effect Case distinction.Depending on the current contents of a field, this statement executes one of several alternative processing branches. The field whose contents determine how the...
- GET PARAMETER: ABAP Keyword a day GET PARAMETER Gets an SPA/GPA parameters. Syntax GET PARAMETER ID <pid> FIELD <field_name>. Writes the value of the SPA/GPA parameter <pid> from the user-specific SAP memory into the variable <f>....



















Leave a Reply