SAP Function Modules

C14K_CHARACT_CREATE SAP Function module







C14K_CHARACT_CREATE is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.

See here to view full function module documentation and code listing, simply by entering the name C14K_CHARACT_CREATE into the relevant SAP transaction such as SE37 or SE80.

Associated Function Group: C14K
Released Date: Not Released
Processing type: Normal fucntion module
Normal function module settings


Pattern for FM C14K_CHARACT_CREATE - C14K CHARACT CREATE





CALL FUNCTION 'C14K_CHARACT_CREATE' "
  EXPORTING
*   i_client = SY-MANDT         " sy-mandt      Client
*   i_key_date = SY-DATUM       " sy-datum      Date
*   i_change_number = SPACE     " cabn-aennr    Change number
    i_charact =                 " cabn-atnam    Characteristic
    i_datatype =                " rctmv-format  Data type
    i_number_of_chars =         " cabn-anzst    Number of characters
*   i_decimal_places = 0        " cabn-anzdz    Number of decimal places
*   i_lowercase = SPACE         " cabn-atkle    Lower Case Letters Allowed
*   i_exponent_display_format = SPACE  " cabn-atdex  Exponent Display Format (0,1,2,3)
*   i_exponent = 0              " cabn-atdim    Exponent
*   i_edit_format = SPACE       " cabn-atsch    Pattern
*   i_negative_vals_allowed = SPACE  " cabn-atvor  Negative values allowed
*   i_unit = SPACE              " rctmv-einh2   Unit
*   i_status = '1'              " cabn-atmst    Status
*   i_charact_group = SPACE     " cabn-atkla    Characteristic group
*   i_entry_required = SPACE    " cabn-aterf    Entry Required
*   i_multiple_values = SPACE   " cabn-atein    Multiple Values Allowed
*   i_interval_vals_allowed = SPACE  " cabn-atint  Intervals allowed
*   i_unformatted_entry = SPACE  " cabn-atfod   Unformatted Entry
*   i_propose_edit_format = SPACE  " cabn-atvsc  Propose Template
*   i_value_assignment = SPACE  " cabn-atwrd    Display Allowed Values During Characteristic Value Assignment
*   i_document = SPACE          " draw-doknr    Document
*   i_document_type = SPACE     " draw-dokar    Document type
*   i_document_part = SPACE     " draw-doktl    Document part
*   i_document_version = SPACE  " draw-dokvr    Document version
*   i_selection_choice = SPACE  " cabn-auswahlmge  Phrase set
  TABLES
    i_apicabnt =                " apicabnt      Description and Headings for Characteristic
*   i_apicawn =                 " apicawn       Allowed Values and Value Descriptions
*   i_apitcme =                 " apitcme       Validity for global characteristics
    .  "  C14K_CHARACT_CREATE

ABAP code example for Function Module C14K_CHARACT_CREATE





The ABAP code below is a full code listing to execute function module C14K_CHARACT_CREATE including all data declarations. The code uses the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the original method of declaring data variables up front. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8).

DATA:
it_i_apicabnt  TYPE STANDARD TABLE OF APICABNT,"TABLES PARAM
wa_i_apicabnt  LIKE LINE OF it_i_apicabnt ,
it_i_apicawn  TYPE STANDARD TABLE OF APICAWN,"TABLES PARAM
wa_i_apicawn  LIKE LINE OF it_i_apicawn ,
it_i_apitcme  TYPE STANDARD TABLE OF APITCME,"TABLES PARAM
wa_i_apitcme  LIKE LINE OF it_i_apitcme .

DATA(ld_i_client) = 'Check type of data required'.
DATA(ld_i_key_date) = '20210129'.

SELECT single AENNR
FROM CABN
INTO @DATA(ld_i_change_number).


SELECT single ATNAM
FROM CABN
INTO @DATA(ld_i_charact).


DATA(ld_i_datatype) = some text here

SELECT single ANZST
FROM CABN
INTO @DATA(ld_i_number_of_chars).


SELECT single ANZDZ
FROM CABN
INTO @DATA(ld_i_decimal_places).


SELECT single ATKLE
FROM CABN
INTO @DATA(ld_i_lowercase).


SELECT single ATDEX
FROM CABN
INTO @DATA(ld_i_exponent_display_format).


SELECT single ATDIM
FROM CABN
INTO @DATA(ld_i_exponent).


SELECT single ATSCH
FROM CABN
INTO @DATA(ld_i_edit_format).


SELECT single ATVOR
FROM CABN
INTO @DATA(ld_i_negative_vals_allowed).


DATA(ld_i_unit) = some text here

SELECT single ATMST
FROM CABN
INTO @DATA(ld_i_status).


SELECT single ATKLA
FROM CABN
INTO @DATA(ld_i_charact_group).


SELECT single ATERF
FROM CABN
INTO @DATA(ld_i_entry_required).


SELECT single ATEIN
FROM CABN
INTO @DATA(ld_i_multiple_values).


SELECT single ATINT
FROM CABN
INTO @DATA(ld_i_interval_vals_allowed).


SELECT single ATFOD
FROM CABN
INTO @DATA(ld_i_unformatted_entry).


SELECT single ATVSC
FROM CABN
INTO @DATA(ld_i_propose_edit_format).


SELECT single ATWRD
FROM CABN
INTO @DATA(ld_i_value_assignment).


SELECT single DOKNR
FROM DRAW
INTO @DATA(ld_i_document).


SELECT single DOKAR
FROM DRAW
INTO @DATA(ld_i_document_type).


SELECT single DOKTL
FROM DRAW
INTO @DATA(ld_i_document_part).


SELECT single DOKVR
FROM DRAW
INTO @DATA(ld_i_document_version).


SELECT single AUSWAHLMGE
FROM CABN
INTO @DATA(ld_i_selection_choice).


"populate fields of struture and append to itab
append wa_i_apicabnt to it_i_apicabnt.

"populate fields of struture and append to itab
append wa_i_apicawn to it_i_apicawn.

"populate fields of struture and append to itab
append wa_i_apitcme to it_i_apitcme. . CALL FUNCTION 'C14K_CHARACT_CREATE' EXPORTING * i_client = ld_i_client * i_key_date = ld_i_key_date * i_change_number = ld_i_change_number i_charact = ld_i_charact i_datatype = ld_i_datatype i_number_of_chars = ld_i_number_of_chars * i_decimal_places = ld_i_decimal_places * i_lowercase = ld_i_lowercase * i_exponent_display_format = ld_i_exponent_display_format * i_exponent = ld_i_exponent * i_edit_format = ld_i_edit_format * i_negative_vals_allowed = ld_i_negative_vals_allowed * i_unit = ld_i_unit * i_status = ld_i_status * i_charact_group = ld_i_charact_group * i_entry_required = ld_i_entry_required * i_multiple_values = ld_i_multiple_values * i_interval_vals_allowed = ld_i_interval_vals_allowed * i_unformatted_entry = ld_i_unformatted_entry * i_propose_edit_format = ld_i_propose_edit_format * i_value_assignment = ld_i_value_assignment * i_document = ld_i_document * i_document_type = ld_i_document_type * i_document_part = ld_i_document_part * i_document_version = ld_i_document_version * i_selection_choice = ld_i_selection_choice TABLES i_apicabnt = it_i_apicabnt * i_apicawn = it_i_apicawn * i_apitcme = it_i_apitcme . " C14K_CHARACT_CREATE
IF SY-SUBRC EQ 0. "All OK ENDIF.







ABAP code to compare 7.40 inline data declaration with original syntax

The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.

DATA:
ld_i_client  TYPE SY-MANDT ,
it_i_apicabnt  TYPE STANDARD TABLE OF APICABNT ,
wa_i_apicabnt  LIKE LINE OF it_i_apicabnt,
ld_i_key_date  TYPE SY-DATUM ,
it_i_apicawn  TYPE STANDARD TABLE OF APICAWN ,
wa_i_apicawn  LIKE LINE OF it_i_apicawn,
ld_i_change_number  TYPE CABN-AENNR ,
it_i_apitcme  TYPE STANDARD TABLE OF APITCME ,
wa_i_apitcme  LIKE LINE OF it_i_apitcme,
ld_i_charact  TYPE CABN-ATNAM ,
ld_i_datatype  TYPE RCTMV-FORMAT ,
ld_i_number_of_chars  TYPE CABN-ANZST ,
ld_i_decimal_places  TYPE CABN-ANZDZ ,
ld_i_lowercase  TYPE CABN-ATKLE ,
ld_i_exponent_display_format  TYPE CABN-ATDEX ,
ld_i_exponent  TYPE CABN-ATDIM ,
ld_i_edit_format  TYPE CABN-ATSCH ,
ld_i_negative_vals_allowed  TYPE CABN-ATVOR ,
ld_i_unit  TYPE RCTMV-EINH2 ,
ld_i_status  TYPE CABN-ATMST ,
ld_i_charact_group  TYPE CABN-ATKLA ,
ld_i_entry_required  TYPE CABN-ATERF ,
ld_i_multiple_values  TYPE CABN-ATEIN ,
ld_i_interval_vals_allowed  TYPE CABN-ATINT ,
ld_i_unformatted_entry  TYPE CABN-ATFOD ,
ld_i_propose_edit_format  TYPE CABN-ATVSC ,
ld_i_value_assignment  TYPE CABN-ATWRD ,
ld_i_document  TYPE DRAW-DOKNR ,
ld_i_document_type  TYPE DRAW-DOKAR ,
ld_i_document_part  TYPE DRAW-DOKTL ,
ld_i_document_version  TYPE DRAW-DOKVR ,
ld_i_selection_choice  TYPE CABN-AUSWAHLMGE .

ld_i_client = 'Check type of data required'.

"populate fields of struture and append to itab
append wa_i_apicabnt to it_i_apicabnt.
ld_i_key_date = '20210129'.

"populate fields of struture and append to itab
append wa_i_apicawn to it_i_apicawn.

SELECT single AENNR
FROM CABN
INTO ld_i_change_number.


"populate fields of struture and append to itab
append wa_i_apitcme to it_i_apitcme.

SELECT single ATNAM
FROM CABN
INTO ld_i_charact.


ld_i_datatype = some text here

SELECT single ANZST
FROM CABN
INTO ld_i_number_of_chars.


SELECT single ANZDZ
FROM CABN
INTO ld_i_decimal_places.


SELECT single ATKLE
FROM CABN
INTO ld_i_lowercase.


SELECT single ATDEX
FROM CABN
INTO ld_i_exponent_display_format.


SELECT single ATDIM
FROM CABN
INTO ld_i_exponent.


SELECT single ATSCH
FROM CABN
INTO ld_i_edit_format.


SELECT single ATVOR
FROM CABN
INTO ld_i_negative_vals_allowed.


ld_i_unit = some text here

SELECT single ATMST
FROM CABN
INTO ld_i_status.


SELECT single ATKLA
FROM CABN
INTO ld_i_charact_group.


SELECT single ATERF
FROM CABN
INTO ld_i_entry_required.


SELECT single ATEIN
FROM CABN
INTO ld_i_multiple_values.


SELECT single ATINT
FROM CABN
INTO ld_i_interval_vals_allowed.


SELECT single ATFOD
FROM CABN
INTO ld_i_unformatted_entry.


SELECT single ATVSC
FROM CABN
INTO ld_i_propose_edit_format.


SELECT single ATWRD
FROM CABN
INTO ld_i_value_assignment.


SELECT single DOKNR
FROM DRAW
INTO ld_i_document.


SELECT single DOKAR
FROM DRAW
INTO ld_i_document_type.


SELECT single DOKTL
FROM DRAW
INTO ld_i_document_part.


SELECT single DOKVR
FROM DRAW
INTO ld_i_document_version.


SELECT single AUSWAHLMGE
FROM CABN
INTO ld_i_selection_choice.

Contribute (Add Comments)

Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name C14K_CHARACT_CREATE or its description.