SAP Program RSTXLITF - Report For Uploading ITF Format From a Dataset

Description
PROTECT
The ITF format is used to import texts from external systems to the R/3word processing system SAPscript. The texts are uploaded as textfiles from the file system of the R/3 server with the report RSTXLITFand stored in the data base.
For large amounts of text, the report should be run in batch. When thedata is stored there is
no locking via enqueue/dequeue mechanism,
no authorization check on user.
Texts which are generally stored via updates are saved directly withthe help report when uploaded.
It is only possible to import texts which are stored in the SAPscripttext file, not, for example, document texts or hypertext modules.
ENDPROTECT
PROTECT

Format of the file which is to be imported:
The file to be imported can have as many texts as required, eachcomprising a header block with administration information, preceded by"/HTEXT", and a main text block, preceded by "/M". The attributelengths allowed are specified in the rounded brackets, the brackets andtheir contents are not part of the text format.
/HTEXT
/:OBJECT object(<=10)
/:NAME name(<=70)
/:ID ID(<=4)
/:LANGUAGE language(=1)
/:FORM form_id(<=16)
/:STYLE style_id(<=8)
/:FIRST-USER identifier(<=12)
/:FIRST-DATE day(<=2) month(<=2) year(=4)
/:FIRST-TIME hour(<=2) minute(<=2) second(<=2)
/:LAST-USER identifier(<=12)
/:LAST-DATE day(<=2) month(<=2) year(=4)
/:LAST-TIME hour(<=2) minute(<=2) second(<=2)
/:TITLE 'title(<=50)'
/:TITLE1 'title1(<=16)'
/:TITLE2 'title2(<=16)'
/M
* Standard paragraph with any text
/ Text line with any text and line break at beginning
Text line with any text without line break at beginning
/ ...
ENDPROTECT
PROTECT

Header block:
The attributes OBJECT, NAME, ID, and LANGUAGE
specify the text key to be used to save in the text file. They mustbe available and defined.
All combinations of OBJECT and ID which occur in theupload must be maintained in the R/3 System in the control table TTXOBor TTXID, otherwise the import is terminated.
NAME is the name of a SAPscript text. The names are always uppercase and can comprise alphabetic, numeric, and special characters. Thefollowing characters are not allowed in names:

  • asterisk (*),

  • slash (/),

  • blank ( ).

  • LANGUAGE is a language indicator which must be defined in tableT002 (for example, 'D' for German).
    ENDPROTECT
    PROTECT
    The attributes from key word FORM onwards are optional. Theycontain administration information, and are filled automatically withdefaults by the report if they are not specified.
    ENDPROTECT
    PROTECT
    The meanings of the attributes are as follows:
    FORM: Specifies the layout set to be used to format the textwith SAPscript. If there is no particular layout set in the R/3 Systemfor the texts which are to be imported, the standard layout set"SYSTEM" can, for example, be used.
    Default value: Layout set names from table TTXOB for thecorresponding text object.
    ENDPROTECT
    PROTECT
    STYLE: The style to be used for text formatting with SAPscript.If a separate style is not maintained in the R/3 System for the textswhich are to be uploaded, the standard style "SYSTEM" can be specifiedhere.
    Default value: Style name from table TTXOB for the correspondingtext object.
    ENDPROTECT
    PROTECT
    FIRST-USER, FIRST-DATE, FIRST-TIME: The name ofthe user (from the R/3 user master) who created the text, and the dateand time the text was created.
    Default values: User name under which the report is carried out(SY-UNAME), and the date and time when the report is executed.
    Note: These attributes are at present not stored when anITF object is uploaded.
    ENDPROTECT
    PROTECT
    LAST-USER, LAST-DATE, LAST-TIME: The name of theuser (from the R/3 user master) who last changed the text, and the dateand time when the text was saved.
    Default values: User name under which the report is executed(SY-UNAME), and the date and time when the report is executed.
    Note: These attributes are at present not stored when anITF object is uploaded.
    ENDPROTECT
    PROTECT
    TITLE, TITLE1, TITLE2: Short title for the text.Can contain any text within the specified maximum width. The text mustbe enclosed in inverted commas ('). The short titles aredisplayed in the SAPscript text editor in the header data of the text.
    Default values: Not defined.
    ENDPROTECT
    PROTECT

    Main text block:
    The actual text is in the main text block. The ITF format requires atwo-character tag column at the beginning of each text line and thenthe actual line of text. The length of the text in the line (withouttag column) is restricted to a maximum of 132 characters. The tagcolumn can contain the following:
    "* " - Beginning of a standard paragraph.
    ENDPROTECT
    PROTECT
    "XX" - Beginning of a paragraph with the paragraph key "XX". When thetext is formatted with SAPscript, this paragraph key must be specifiedin the style or layout set allocated, otherwise the standard paragraphis used. Paragraph keys can have one or two characters, and must beginwith a letter and end with a letter or number.
    The use of special paragraph keys when uploading texts requires acorresponding style or layout set definition in the R/3 System, wherethe attributes of the paragraphs used are defined. If the texts whichare uploaded have no particular paragraph attributes, the asterisk (*),the character for standard paragraphs, can be used to define theparagraphs.
    ENDPROTECT
    PROTECT
    "/ " - Beginning of a new line in the current paragraph. The linebreaks of the texts which are to be imported can then be transferred toSAPscript.
    ENDPROTECT
    PROTECT
    " " - Continuation of a line in the current paragraph without a linebreak at the beginning of the line. Lines which are longer than 132characters can therefore also be transferred in OTF format withoutunwanted line breaks.
    ENDPROTECT
    PROTECT
    "/*" - Comment line which is not output when the text if formatted.
    The characters in the tag column have the same meaning as when entereddirectly using the SAPscript text editor.
    ENDPROTECT
    PROTECT

    Parameter of RSTXLITF
    The following are used as parameters to call up the report:
    Dataset name: name of the dataset (for example, path or filename in UNIX)
    ENDPROTECT
    PROTECT
    Test import without saving: If the flag is set ("X"), the ITFformat is only checked for syntactical correctness, and all textsalready available in the R/3 System, which could be overwritten duringthe import, are listed. Here the parameter Overwrite... is notsignificant.
    If the flag is deactivated (set to blank), the actual text import takesplace.
    ENDPROTECT
    PROTECT
    Overwrite existing obj.: If this flag is set ("X"), textsalready available in the system will be overwritten during the import.
    If the flag is deactivated (set to blank), only new texts will bestored in the system.
    ENDPROTECT
    PROTECT
    Print statistics: If this flag is set ("X"), a list is outputwith statistical information about the texts which are to be uploaded.
    ENDPROTECT
    PROTECT
    Character set number: If a character set conversion is to takeplace before the text import, the identification of the character set,in which the text is stored in the file, must be specified here. If anentry is not made here, the system assumes the dataset is available inthe R/3 system character set and a conversion is not necessary.
    Character sets are identified in the R/3 System by four-characternumbers. The character sets used here must be defined in the system andshould have no multibyte characters, all characters maytherefore only be encrypted using a single byte. If the character setis not the same as the system character set, the character setspecified is converted to the R/3 system character set before the textimport. When the character set is converted, unknown characters arereplaced by the hash (<35>).
    ENDPROTECT
    PROTECT
    Only character set conversion: If this flag is set ("X"), a dataimport does not take place, only a character set conversion of thedataset (the character set specified as a parameter is converted to theR/3 system character set). The contents of the dataset are listed whenthe conversion is complete.
    ENDPROTECT
    PROTECT

    Text key for texts in the text file:
    An imported text is stored in the text file under the key
    object , name , ID , language .
    All four components of the text key must be defined in the header blockof each text in the file which is to be imported.
    ENDPROTECT

    Precondition
    See above

    Output
    The report creates a list in which all steps of the text import arelogged, such as faulty objects in the dataset, objects which cannot beimported, objects which have been stored, etc.

    Example
    PROTECT

    An example of a file for importing texts:
    /HTEXT
    /:OBJECT TEXT
    /:NAME SAPSCRIPT-TEXTIMPORT
    /:ID ST
    /:LANGUAGE D
    /:FORM SYSTEM
    /:STYLE SYSTEM
    /:FIRST-USER SAP*
    /:FIRST-DATE 1 12 1992
    /:FIRST-TIME 10 50 0
    /:LAST-USER SAP*
    /:LAST-DATE 2 12 1992
    /:LAST-TIME 13 40 5
    /:TITLE 'Info text for text import'
    /:TITLE2 'Draft'
    /M
    * RSTXLITF - Report for uploading ITF text format
    * This report loads ITF format from a dataset and stores it
    in the SAPscript text file.
    / The report allows several texts to be loaded from one file.
    /HTEXT
    /:OBJECT TEXT
    /:NAME IMPORT_DEMO
    /:ID ST
    /:LANGUAGE E
    /:FORM SYSTEM
    /:STYLE SYSTEM
    /:FIRST-USER SAP*
    /:FIRST-DATE 3 12 1992
    /:FIRST-TIME 9 30 0
    /:TITLE 'Demonstration of text upload'
    /M
    * This is a demonstration of how a file containing
    texts to be uploaded into R/3 would look like.
    ENDPROTECT

191669LSMW: Importing long texts using RSTXLITF
481034FAQ: Data transfer (batch input) in purchasing
638362FAQ: Data transfer in the service