ABAP Cursosentenciasubtractcorresponding

<html>

<head>

<title>SUBTRACT-CORRESPONDING</title>

</head>

<BODY BGCOLOR="#000000" TEXT="#FFFFFF" LINK="#0099FF" VLINK="#AA0000">

<p align="left">⚠ <b class="titulo">SUBTRACT-CORRESPONDING⚠ </b></p>

<p align="left">⚠ <b>Definicin⚠ </b></p>

<p align="left">Substrae el contenido de campos de una estructura. </p>

<p align="left">⚠ <b>Sintaxis:⚠ </b></p>

<p>SUBTRACT-CORRESPONDING <n> FROM <m>.</p>

<p>Substrae el contenido de los componentes del registro <n>

  del registro <m>, para aquellos componentes que se llamen igual.</p>

<p align="left">⚠ <b>Ejemplo:⚠ </b></p>

<p>DATA: BEGIN OF PERSON,<br>

  NAME(20) VALUE 'Paul',<br>
  MONEY TYPE I VALUE 5000,<br>
  END OF PERSON,<br>
  BEGIN OF PURCHASES OCCURS 10,<br>
  PRODUCT(10),<br>
  MONEY TYPE I,<br>
  END OF PURCHASES.<br>
  PURCHASES-PRODUCT = 'Table'.<br>
  PURCHASES-MONEY = 100.<br>
  APPEND PURCHASES.</p>

<p>PURCHASES-PRODUCT = 'Chair'.<br>

  PURCHASES-MONEY = 70.<br>
  APPEND PURCHASES.</p>

<p>LOOP AT PURCHASES.<br>

  SUBTRACT-CORRESPONDING PURCHASES FROM PERSON.<br>
  ENDLOOP.</p>

<p align="left">El campo PERSON-MONEY valdr 4830</p>

<p align="left">⚠ <b>Vase tambin⚠ </b>: ⚠ <a href="subtract.htm" tppabs="http://www.gaussr3.com/abap4/sentencias/subtract.htm">SUBTRACT⚠ </a>, ⚠ <a href="add_corresponding.htm" tppabs="http://www.gaussr3.com/abap4/sentencias/add_corresponding.htm">ADD-CORRESPONDING⚠ </a>,

  ⚠ <a href="multiply_corresponding.htm" tppabs="http://www.gaussr3.com/abap4/sentencias/multiply_corresponding.htm">MULTIPLY-CORRESPONDING⚠ </a>, ⚠ <a href="divide_corresponding.htm" tppabs="http://www.gaussr3.com/abap4/sentencias/divide_corresponding.htm">DIVIDE-CORRESPONDING⚠ </a>.</p>

</body>

</html>