MULTIPLY-CORRESPONDING (ABAP Keyword)

MULTIPLY-CORRESPONDING is a keyword used in SAP ABAP programming.This tutorial covers its introduction & syntax details.

MULTIPLY-CORRESPONDING


Basic form
MULTIPLY-CORRESPONDING rec1 BY rec2.

Effect
Interprets rec1 and rec2 as field strings. If, for example, rec1 and rec2 are tables, executes the statement for their header lines.
Searches for all sub-fields which occur both in rec1 and rec2 and then generates, for all field pairs corresponding to the sub-fields ni , statements of the form


MULTIPLY rec1-ni BY rec2-ni.


The other fields remain unchanged.

With complex structures, the full names of the corresponding field pairs must be identical.

Example

DATA: BEGIN OF MONEY,
VALUE_IN(20) VALUE 'German marks'.
USA TYPE I VALUE 100,
FRG TYPE I VALUE 200,
AUT TYPE I VALUE 300,
END OF MONEY,
BEGIN OF CHANGE,
DESCRIPTION(30)
VALUE 'DM to national currency'.
USA TYPE F VALUE '0.6667',
FRG TYPE F VALUE '1.0',
AUT TYPE F VALUE '7.0',
END OF CHANGE.
MULTIPLY-CORRESPONDING MONEY BY CHANGE.
MONEY-VALUE_IN = 'National currency'.


The above MULTIPLY-CORRESPONDING statement is equivalent to the following three statements:


MULTIPLY MONEY-USA BY CHANGE-USA.
MULTIPLY MONEY-FRG BY CHANGE-FRG.
MULTIPLY MONEY-AUT BY CHANGE-AUT.



Note
All fields with identical names are multiplied, whether numeric or not. The conversions performed are similar to those for MULTIPLY and the same runtime errors can also occur.

Most readed SAP Tutorials

Latest Added SAP documents

Custom Search
ABAP Tutorials ABAP Syntax BAPI SAP Jobs SAP Glossary SAP Netweaver SAP XI SAP Download SAP Interview questions

Complete SAP Study materials | SAP JOBS | PDF Tutorials   List of SAP Companies India

Google-Translate-Chinese (Simplified) BETA Google-Translate-English to French Google-Translate-English to German Google-Translate-English to Italian Google-Translate-English to Japanese BETA Google-Translate-English to Korean BETA Google-Translate-English to Russian BETA Google-Translate-English to Spanish

All of the product names here are trademarks of their respective companies. The site sapbrainsonline.com no way affiliated with SAP AG. Use information on this site at your own risk. Information furnished in the site is collected from various sites and posts from users. This site does not host any files on its server. If any compliants about the posts please contact us at sapbrain.support@gmail.com

Sitemap
web counter