<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: update sap table using a function module call by php code in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-sap-table-using-a-function-module-call-by-php-code/m-p/6628025#M1441499</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I use COMMIT WORK&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 26 Feb 2010 15:00:30 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2010-02-26T15:00:30Z</dc:date>
    <item>
      <title>update sap table using a function module call by php code</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-sap-table-using-a-function-module-call-by-php-code/m-p/6628024#M1441498</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I m trying to update the table VBAP using a function module ZZ_SET_DISTANCE  call by a php code.&lt;/P&gt;&lt;P&gt;But I have this problem: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the saprfc seems to work well but when I look to the table VBAP the fields have not been update. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tried the function module in debug mode and it work good. The fields are update.&lt;/P&gt;&lt;P&gt;I also handle the saprfc call function and the return SAPRFC_OK&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This are the function module ZZ_SET_DISTANCE, and the php code&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;//PHP CODE&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$fce = saprfc_function_discover($sap,"ZZ_SET_DISTANCE");&lt;/P&gt;&lt;P&gt;		    if (! $fce ) {echo "Echec d'ouverture du module fonction "; exit;}&lt;/P&gt;&lt;P&gt;			saprfc_import ($fce,"COMMANDE", '0000001998');&lt;/P&gt;&lt;P&gt;			saprfc_table_init($fce,"TBLE_CMDE");&lt;/P&gt;&lt;P&gt;				$val=array();&lt;/P&gt;&lt;P&gt;				$val['NUM_POST']='000030';&lt;/P&gt;&lt;P&gt;				$val['HN_EXP']='';&lt;/P&gt;&lt;P&gt;				$val['ST_EXP']='';&lt;/P&gt;&lt;P&gt;				$val['PC_EXP']='';&lt;/P&gt;&lt;P&gt;				$val['CI_EXP']='';&lt;/P&gt;&lt;P&gt;				$val['CO_EXP']='';&lt;/P&gt;&lt;P&gt;				$val['HN_REC']='';&lt;/P&gt;&lt;P&gt;				$val['ST_REC']='';&lt;/P&gt;&lt;P&gt;				$val['PC_REC']='';&lt;/P&gt;&lt;P&gt;				$val['CI_REC']='';&lt;/P&gt;&lt;P&gt;				$val['CO_REC']='';&lt;/P&gt;&lt;P&gt;				$val['DIST']='popo';&lt;/P&gt;&lt;P&gt;				saprfc_table_append ($fce,"TBLE_CMDE", $val);&lt;/P&gt;&lt;P&gt;			&lt;/P&gt;&lt;P&gt;			&lt;/P&gt;&lt;P&gt;		   $rfc_rc = saprfc_call_and_receive ($fce);&lt;/P&gt;&lt;P&gt;		   echo "\n".$rfc_rc;&lt;/P&gt;&lt;P&gt;		   if ($rfc_rc != SAPRFC_OK) { if ($sap == SAPRFC_EXCEPTION ) echo ("Exception raised: ".saprfc_exception($fce)); else echo (saprfc_error($fce)); }else{echo '/execution de la function ;}&lt;/P&gt;&lt;P&gt;		   saprfc_function_free($fce);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;//FUNCTION MODULE ZZ_SET_DISTANCE&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FUNCTION ZZ_SET_DISTANCE.&lt;/P&gt;&lt;P&gt;*"----&lt;/P&gt;&lt;HR originaltext="-----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;STRONG&gt;"&lt;/STRONG&gt;"Local Interface:&lt;/P&gt;&lt;P&gt;*"  IMPORTING&lt;/P&gt;&lt;P&gt;*"     VALUE(COMMANDE) TYPE  VBELN&lt;/P&gt;&lt;P&gt;*"  TABLES&lt;/P&gt;&lt;P&gt;*"      TBLE_CMDE STRUCTURE  ZADD_COM_LOXAN&lt;/P&gt;&lt;P&gt;*"----&lt;/P&gt;&lt;HR originaltext="-----------------------------------------------------------------" /&gt;&lt;P&gt;DATA : NUMC TYPE VBELN.&lt;/P&gt;&lt;P&gt;NUMC = COMMANDE .&lt;/P&gt;&lt;P&gt;WHILE STRLEN( NUMC ) &amp;lt; 10 .&lt;/P&gt;&lt;P&gt;  CONCATENATE '0' NUMC INTO NUMC .&lt;/P&gt;&lt;P&gt;ENDWHILE .&lt;/P&gt;&lt;P&gt;DATA tble_addrcomm LIKE LINE OF TBLE_CMDE .&lt;/P&gt;&lt;P&gt;LOOP AT  TBLE_CMDE INTO  tble_addrcomm.&lt;/P&gt;&lt;P&gt;  DATA : NUMP TYPE POSNR.&lt;/P&gt;&lt;P&gt;  NUMP = tble_addrcomm-NUM_POST.&lt;/P&gt;&lt;P&gt;  WHILE STRLEN( NUMP ) &amp;lt; 6 .&lt;/P&gt;&lt;P&gt;  CONCATENATE '0' NUMP INTO NUMP .&lt;/P&gt;&lt;P&gt;  ENDWHILE .&lt;/P&gt;&lt;P&gt;  UPDATE VBAP SET ARKTX = tble_addrcomm-DIST&lt;/P&gt;&lt;P&gt;  WHERE VBELN EQ COMMANDE&lt;/P&gt;&lt;P&gt;  AND POSNR EQ NUMP.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFUNCTION.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is anybody can help me?&lt;/P&gt;&lt;P&gt;thank.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 01 Feb 2010 15:42:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-sap-table-using-a-function-module-call-by-php-code/m-p/6628024#M1441498</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-02-01T15:42:42Z</dc:date>
    </item>
    <item>
      <title>Re: update sap table using a function module call by php code</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-sap-table-using-a-function-module-call-by-php-code/m-p/6628025#M1441499</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I use COMMIT WORK&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Feb 2010 15:00:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-sap-table-using-a-function-module-call-by-php-code/m-p/6628025#M1441499</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-02-26T15:00:30Z</dc:date>
    </item>
    <item>
      <title>Re: update sap table using a function module call by php code</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-sap-table-using-a-function-module-call-by-php-code/m-p/6628026#M1441500</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well done! That's exactly what you were missing. Glad you found it for yourself.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Mar 2010 17:07:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-sap-table-using-a-function-module-call-by-php-code/m-p/6628026#M1441500</guid>
      <dc:creator>NigelJames180</dc:creator>
      <dc:date>2010-03-11T17:07:36Z</dc:date>
    </item>
    <item>
      <title>Re: update sap table using a function module call by php code</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-sap-table-using-a-function-module-call-by-php-code/m-p/6628027#M1441501</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Marie,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am facing same problem. It will be great help if you could provide more information on the solution.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks !&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Mar 2015 13:45:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-sap-table-using-a-function-module-call-by-php-code/m-p/6628027#M1441501</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2015-03-23T13:45:56Z</dc:date>
    </item>
    <item>
      <title>Re: update sap table using a function module call by php code</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/update-sap-table-using-a-function-module-call-by-php-code/m-p/6628028#M1441502</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Marie, create a Blog please, about more details for dummies....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1) how to connect to sap system?&lt;/P&gt;&lt;P&gt;2) you run the php code where? in a webserver or where?&lt;/P&gt;&lt;P&gt;3) wich is the url for run the FM: &lt;SPAN style="color: #333333; font-size: 12px;"&gt;ZZ_SET_DISTANCE &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-size: 12px;"&gt;4) you placed some dlls files on the web server?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;please is interesting this...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Apr 2015 23:56:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/update-sap-table-using-a-function-module-call-by-php-code/m-p/6628028#M1441502</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2015-04-08T23:56:39Z</dc:date>
    </item>
  </channel>
</rss>

