SAP ADDRESS_ASSIGN Function Module for NOTRANSL: Selektieren, anzeigen und bearbeiten von Anschriften und Zusatzd
ADDRESS_ASSIGN is a standard address assign SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for NOTRANSL: Selektieren, anzeigen und bearbeiten von Anschriften und Zusatzd processing and below is the pattern details for this FM, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.
See here to view full function module documentation and code listing for address assign FM, simply by entering the name ADDRESS_ASSIGN into the relevant SAP transaction such as SE37 or SE38.
Function Group: FVAZ
Program Name: SAPLFVAZ
Main Program:
Appliation area: F
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function ADDRESS_ASSIGN pattern details
In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.CALL FUNCTION 'ADDRESS_ASSIGN'"NOTRANSL: Selektieren, anzeigen und bearbeiten von Anschriften und Zusatzd.
EXPORTING
* ADRZUS_FUNCTION = ' ' "DE-EN-LANG-SWITCH-NO-TRANSLATION
* ADRZUS_IN = ' ' "Address-object relationship
* ADR_IN = ' ' "Object number (virtual object)
* FLG_SAVE_IN_UPDT = ' ' "
* FUNCTION = ' ' "DE-EN-LANG-SWITCH-NO-TRANSLATION
* OBJEKTTYP = ' ' "Object type for objects to which addresses are assigned
IMPORTING
ADRWA_OUT = "Address table
ADRZUS_OUT = "Address-object relationship
FLG_CHANGED = "DE-EN-LANG-SWITCH-NO-TRANSLATION
EXCEPTIONS
ADDRESS_NOT_FOUND = 1 ILLEGAL_FUNCTION = 2 NO_ADDRESS_ASSIGNED = 3
IMPORTING Parameters details for ADDRESS_ASSIGN
ADRZUS_FUNCTION - DE-EN-LANG-SWITCH-NO-TRANSLATION
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
ADRZUS_IN - Address-object relationship
Data type: SANO1Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
ADR_IN - Object number (virtual object)
Data type: SANO1-OBJNRDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
FLG_SAVE_IN_UPDT -
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
FUNCTION - DE-EN-LANG-SWITCH-NO-TRANSLATION
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
OBJEKTTYP - Object type for objects to which addresses are assigned
Data type: SANO1-OBTYPDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for ADDRESS_ASSIGN
ADRWA_OUT - Address table
Data type: SANS1Optional: No
Call by Reference: No ( called with pass by value option)
ADRZUS_OUT - Address-object relationship
Data type: SANO1Optional: No
Call by Reference: No ( called with pass by value option)
FLG_CHANGED - DE-EN-LANG-SWITCH-NO-TRANSLATION
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
ADDRESS_NOT_FOUND - DE-EN-LANG-SWITCH-NO-TRANSLATION
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
ILLEGAL_FUNCTION - DE-EN-LANG-SWITCH-NO-TRANSLATION
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
NO_ADDRESS_ASSIGNED - DE-EN-LANG-SWITCH-NO-TRANSLATION
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for ADDRESS_ASSIGN Function Module
The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than 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 newer method of declaring data variables on the fly. 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), which i why i have stuck to the origianl for this example.| DATA: | ||||
| lv_adrwa_out | TYPE SANS1, " | |||
| lv_adrzus_function | TYPE SANS1, " SPACE | |||
| lv_address_not_found | TYPE SANS1, " | |||
| lv_adrzus_in | TYPE SANO1, " SPACE | |||
| lv_adrzus_out | TYPE SANO1, " | |||
| lv_illegal_function | TYPE SANO1, " | |||
| lv_adr_in | TYPE SANO1-OBJNR, " SPACE | |||
| lv_flg_changed | TYPE SANO1, " | |||
| lv_no_address_assigned | TYPE SANO1, " | |||
| lv_flg_save_in_updt | TYPE SANO1, " SPACE | |||
| lv_function | TYPE SANO1, " SPACE | |||
| lv_objekttyp | TYPE SANO1-OBTYP. " SPACE |
|   CALL FUNCTION 'ADDRESS_ASSIGN' "NOTRANSL: Selektieren, anzeigen und bearbeiten von Anschriften und Zusatzd |
| EXPORTING | ||
| ADRZUS_FUNCTION | = lv_adrzus_function | |
| ADRZUS_IN | = lv_adrzus_in | |
| ADR_IN | = lv_adr_in | |
| FLG_SAVE_IN_UPDT | = lv_flg_save_in_updt | |
| FUNCTION | = lv_function | |
| OBJEKTTYP | = lv_objekttyp | |
| IMPORTING | ||
| ADRWA_OUT | = lv_adrwa_out | |
| ADRZUS_OUT | = lv_adrzus_out | |
| FLG_CHANGED | = lv_flg_changed | |
| EXCEPTIONS | ||
| ADDRESS_NOT_FOUND = 1 | ||
| ILLEGAL_FUNCTION = 2 | ||
| NO_ADDRESS_ASSIGNED = 3 | ||
| . " ADDRESS_ASSIGN | ||
ABAP code using 7.40 inline data declarations to call FM ADDRESS_ASSIGN
The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8.| DATA(ld_adrzus_function) | = ' '. | |||
| DATA(ld_adrzus_in) | = ' '. | |||
| "SELECT single OBJNR FROM SANO1 INTO @DATA(ld_adr_in). | ||||
| DATA(ld_adr_in) | = ' '. | |||
| DATA(ld_flg_save_in_updt) | = ' '. | |||
| DATA(ld_function) | = ' '. | |||
| "SELECT single OBTYP FROM SANO1 INTO @DATA(ld_objekttyp). | ||||
| DATA(ld_objekttyp) | = ' '. | |||
Search for further information about these or an SAP related objects