Saprfc - Php 5.3 - Ecc 6

Hi all
Can anyone pls tell me the version of saprfc to be installed for php version 5.3 in order to work with Sap Ecc 6.0.
Thanks in advance

Well the problem is that unfortunately despite being the language that powers the web, SAP doesn't support PHP very well. It is a problem that I work behind the sceens to try to address and as you are moving to ECC6 if you are calling RFC's with deep structures then the SAPRFC won't work at all because it doesn't work with the new NW RFC SDK.
Oh that a C guru would pick this problem up and write a new RFC driver. Oh that SAP would hire one or Zend or iBuildings or another company that feels strongly about enterprise php.
Oh that I was a C guru and had oooodles of time available.
I digress....
There is no PAM for the SAPRFC because it is an open source solution.
Sorry ... that's all there is to it.
You may get the current version running with the new set up but beware of the new NW REFSDK issues.
Feel free to write a blog to describe how useful you find having PHP as an interface to SAP. The more voices the better.
regards,
Nigel

Similar Messages

  • SAPRFC / PHP 5.3.0 / MacOSX Snow Leopard

    <pre>(seems message parsing is not working..) Hello gurus !
    I've read with a great interrest almost all posts on this forum, and I must say it helped me a lot sorting
    out a nearly functional solution for installing SAPRFC PHP extension on a MacOSX Snow Leopard system.
    It seems i'm just having a problem with the RFCSDK from SAP not being of the appropriate architecture.
    Let me describe my installation process (maybe it can help other people willing to install SAPRFC on
    Macintosh plateform equally !)
    1. Installation of Macintosh developpement tools (Xcode)
    First step was to install XCode Package, from http://developer.apple.com/tools/xcode/ it's a 650Mb
    disk-image, that once installed is 2.5Gb on harddrive. This provided me with all php headers that I
    needed for the next steps.
    I made sure my Apache/PHP was functionnal on the Macintosh, this page helped me :
    http://www.mac4ever.com/articles/creation/1153/php_mysql_sous_snow_leopard_et_xdebug_eclipse/ (it's in french)
    2. Download of RFCSDK from SAP
    I was not totally sure which version to install on my system since no "MacOsX version", so I picked
    the "Linux on x86_64 64bit" package.
    3. Extracting files from the SAR archive
    As the binary of SAPCAR was not willing to execute properly, I downloaded a Windows version and
    extracted my files on a Windows system.
    4. Installing RFCSDK files on the system
    I created a folder "sap" in folder "/usr" :
    $> sudo mkdir /usr/sap
    I created a folder "rfcsdk" in folder "/usr/sap"
    $> sudo mkdir /usr/sap/rfcsdk
    I copied all files i extracted from the SAR archive into the "/usr/sap/rfcsdk folder" :
    $> sudo cp -R ~/Desktop/Linux\ on\ x86_64\ 64bit/ /usr/sap/rfcsdk/*
    After this in "/usr/sap/rfcsdk" i have now : 4 folders : bin, include, lib and text
    I changed access rights for all the files in sap directory:
    $> sudo chmod -R 755 /usr/sap
    5. Compiling SAPRFC extension for PHP
    I downloaded SAPRFC 1.4.1 from http://saprfc.sourceforge.net/
    I created a folder module under "/usr/sap" :
    $> sudo mkdir "/usr/sap/module"
    I unpacked the files from the saprfc-1.4.1.tar.gz archive into "/usr/sap/module/"
    I ran phpize while in folder "/usr/sap/module/"
    $> cd /usr/sap/module
    $> sudo phpize
    Configuring for:
    PHP Api Version:         20090626
    Zend Module Api No:      20090626
    Zend Extension Api No:   220090626
    (I made sure the phpize which was called was the one corresponding to the php version i was
    running with apache, "locate phpize" helped me to sort out if there was serveral phpize that could
    potentially be executed)
    I ran then the configuration script
    $> sudo ./configure
    checking for grep that handles long lines and -e... /usr/bin/grep
    checking for egrep... /usr/bin/grep -E
    checking for a sed that does not truncate output... /usr/bin/sed
    checking for cc... cc
    checking how to hardcode library paths into programs... immediate
    checking whether stripping libraries is possible... yes
    checking if libtool supports shared libraries... yes
    checking whether to build shared libraries... yes
    checking whether to build static libraries... no
    creating libtool
    appending configuration tag "CXX" to libtool
    configure: creating ./config.status
    config.status: creating config.h
    config.status: config.h is unchanged
    Then i ran the compilation :
    $> sudo make
    /bin/sh /usr/sap/module/libtool --mode=compile cc  -I. -I/usr/sap/module -DPHP_ATOM_INC
    -I/usr/sap/module/include -I/usr/sap/module/main -I/usr/sap/module -I/usr/include/php
    -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext
    -I/usr/include/php/ext/date/lib -I/usr/sap/rfcsdk/include  -DHAVE_CONFIG_H  -g -O2  
    -c /usr/sap/module/saprfc.c -o saprfc.lo
    mkdir .libs
    cc -I. -I/usr/sap/module -DPHP_ATOM_INC -I/usr/sap/module/include -I/usr/sap/module/main
    -I/usr/sap/module -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend
    -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/sap/rfcsdk/include -DHAVE_CONFIG_H -g -O2 -
    c /usr/sap/module/saprfc.c  -fno-common -DPIC -o .libs/saprfc.o
    /usr/sap/module/saprfc.c: In function '__callback_dispatch':
    /usr/sap/module/saprfc.c:263: warning: format not a string literal and no format arguments
    /bin/sh /usr/sap/module/libtool --mode=compile cc  -I. -I/usr/sap/module -DPHP_ATOM_INC
    -I/usr/sap/module/include -I/usr/sap/module/main -I/usr/sap/module -I/usr/include/php
    -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext
    -I/usr/include/php/ext/date/lib -I/usr/sap/rfcsdk/include  -DHAVE_CONFIG_H  -g -O2  
    -c /usr/sap/module/rfccal.c -o rfccal.lo
    cc -I. -I/usr/sap/module -DPHP_ATOM_INC -I/usr/sap/module/include -I/usr/sap/module/main
    -I/usr/sap/module -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM
    -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/sap/rfcsdk/include
    -DHAVE_CONFIG_H -g -O2 -c /usr/sap/module/rfccal.c  -fno-common -DPIC -o .libs/rfccal.o
    /usr/sap/module/rfccal.c: In function 'cal_allocate':
    /usr/sap/module/rfccal.c:36: warning: format '%d' expects type 'int', but argument 2 has type 'long unsigned int'
    /usr/sap/module/rfccal.c:50: warning: format '%d' expects type 'int', but argument 2 has type 'long unsigned int'
    /bin/sh /usr/sap/module/libtool --mode=link cc -DPHP_ATOM_INC -I/usr/sap/module/include -I/usr/sap/module/main -
    I/usr/sap/module -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend
    -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/sap/rfcsdk/include  -DHAVE_CONFIG_H  -g -O2  
    -o saprfc.la -export-dynamic -avoid-version -prefer-pic -module -rpath /usr/sap/module/modules 
    saprfc.lo rfccal.lo -Wl,-rpath,/usr/sap/rfcsdk/lib -L/usr/sap/rfcsdk/lib -lrfccm
    cc ${wl}-flat_namespace ${wl}-undefined ${wl}suppress -o .libs/saprfc.so -bundle 
    .libs/saprfc.o .libs/rfccal.o  -L/usr/sap/rfcsdk/lib -lrfccm -Wl,-rpath -Wl,/usr/sap/rfcsdk/lib
    +ld: warning: in /usr/sap/rfcsdk/lib/librfccm.so, file is not of required architecture+
    creating saprfc.la
    (cd .libs && rm -f saprfc.la && ln -s ../saprfc.la saprfc.la)
    /bin/sh /usr/sap/module/libtool --mode=install cp ./saprfc.la /usr/sap/module/modules
    cp ./.libs/saprfc.so /usr/sap/module/modules/saprfc.so
    cp ./.libs/saprfc.lai /usr/sap/module/modules/saprfc.la
    Libraries have been installed in:
       /usr/sap/module/modules
    If you ever happen to want to link against installed libraries
    in a given directory, LIBDIR, you must either use libtool, and
    specify the full pathname of the library, or use the `-LLIBDIR'
    flag during linking and do at least one of the following:
       - add LIBDIR to the `DYLD_LIBRARY_PATH' environment variable
         during execution
    See any operating system documentation about shared libraries for
    more information, such as the ld(1) and ld.so(8) manual pages.
    Build complete.
    Don't forget to run 'make test'.
    And here seems the problem to be :
    ld: warning: in /usr/sap/rfcsdk/lib/librfccm.so, file is not of required architecture
    I continued anyway :
    $> sudo make install
    Installing shared extensions:     /usr/lib/php/extensions/no-debug-non-zts-20090626/
    6. Installing the PHP extension in the PHP.ini
    I went to /etc and stated editing php.ini :
    $> sudo vi /etc/php.ini
    I went to the extensions part and added the line :
    extension     = "/usr/lib/php/extensions/no-debug-non-zts-20090626/saprfc.so"
    +(for some reason, when setting extension = saprfc.so, i had some errors, while the
    extension folder was defined to extensions/no-debug-non-zts-20090626 ... no clue
    why, nevermind, works better with full path...)+
    ;   extension=/path/to/extension/msql.so
    ; If you only provide the name of the extension, PHP will look for it in its
    ; default extension directory.
    extension     = "/usr/lib/php/extensions/no-debug-non-zts-20090626/saprfc.so"
    ; Windows Extensions
    ; Note that ODBC support is built in, so no dll is needed for it.
    ; Note that many DLL files are located in the extensions/ (PHP 4) ext/ (PHP 5)
    ; extension folders as well as the separate PECL DLL download (PHP 5).
    ; Be sure to appropriately set the extension_dir directive.
    ;extension=php_bz2.dll
    ;extension=php_curl.dll
    I saved my php.ini file forcing write of the read only file (Esc, ":wq!", enter)
    7. Testing the installation
    I restarted my apache server, and checked /var/log/apache2/error_log; at this time no
    error shows here yet.
    I put the saprfc_test.php file in my Sites/ folder to test it with http://localhost// and the page
    just load fine, and the php script seems to not fail on the test : if (! extension_loaded ("saprfc")),
    so.. normally the extension is loaded by php.
    After viewing the saprfc_test.php page, some errors appears in the /var/log/apache2/error_log :
    dyld: lazy symbol binding failed: Symbol not found: _RfcGetAllLibVersions
      Referenced from: /usr/lib/php/extensions/no-debug-non-zts-20090626/saprfc.so
      Expected in: flat namespace
    dyld: Symbol not found: _RfcGetAllLibVersions
      Referenced from: /usr/lib/php/extensions/no-debug-non-zts-20090626/saprfc.so
      Expected in: flat namespace
    8. Trying to find out the issue
    I wanted to run LDD tool on saprfc.so to find out if the linking was correctly done with the library
    "/usr/sap/rfcsdk/lib/librfccm.so" but it appears that ldd is not available on MacOSX and Apple
    recommand using "otool -L" instead.
    Here we go :
    *$> cd /usr/lib/php/extensions/no-debug-non-zts-20090626
    *$> otool -L saprfc.so"
    saprfc.so:
         /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 125.0.0)
    Not very "verbose".. i tried the otool -l (minus L) to view any better info :
    *$> otool -l saprfc.so"
    saprfc.so:
    Load command 0
          cmd LC_SEGMENT_64
      cmdsize 552
      segname __TEXT
       vmaddr 0x0000000000000000
       vmsize 0x0000000000011000
      fileoff 0
    filesize 69632
       vmaddr 0x0000000000013000
       vmsize 0x0000000000006000
      fileoff 73728
    filesize 22088
      maxprot 0x00000007
    initprot 0x00000001
       nsects 0
        flags 0x0
    Load command 3
         cmd LC_UUID
    cmdsize 24
       uuid 0x21 0xea 0x9e 0x15 0xca 0x1c 0xd8 0xe8
            0x35 0x3e 0x54 0x86 0x3e 0x58 0xa1 0x8a
    Load command 4
                cmd LC_DYLD_INFO_ONLY
            cmdsize 48
         rebase_off 73728
        rebase_size 16
           bind_off 73744
          bind_size 1272
      weak_bind_off 0
    weak_bind_size 0
      lazy_bind_off 75016
    lazy_bind_size 2992
         export_off 78008
        export_size 1560
    Load command 5
         cmd LC_SYMTAB
    cmdsize 24
      symoff 79568
       nsyms 575
      stroff 89760
    strsize 6056
    Load command 6
                cmd LC_DYSYMTAB
            cmdsize 80
          ilocalsym 0
          nlocalsym 405
         iextdefsym 405
         nextdefsym 75
          iundefsym 480
          nundefsym 95
             tocoff 0
               ntoc 0
          modtaboff 0
            nmodtab 0
       extrefsymoff 0
        nextrefsyms 0
    indirectsymoff 88768
      nindirectsyms 247
          extreloff 0
            nextrel 0
          locreloff 0
            nlocrel 0
    Load command 7
              cmd LC_LOAD_DYLIB
          cmdsize 56
             name /usr/lib/libSystem.B.dylib (offset 24)
       time stamp 2 Thu Jan  1 01:00:02 1970
          current version 125.0.0
    compatibility version 1.0.0
    Load command 8
              cmd LC_RPATH
          cmdsize 32
             path /usr/sap/rfcsdk/lib (offset 12)
    OK this time, seems there is at least 1 mention of my RFCSDK in the last line, but .. just a path to the
    lib folder, no mention to the library file it self.. i'm just a bit confused now !
    Thank you for reading all this, now, maybe you if already managed to have a MacOSX SAPRFC
    working or have any clue where I can find a RFCSDK library (or compilable sources) that would
    just work on a Mac OSX system.. Thanks for your kind advices
    Edited by: Lemmus on Dec 22, 2009 1:59 PM
    Edited by: Julius Bussche on Dec 22, 2009 4:05 PM
    Fixed formating a bit </pre>

    Hey that is one crazy message Lemmus. If you want people to respond a little human parsing and indenting maybe required.
    I have one thought.
    What version on SAP are you connecting to? If it is ECC6 or a netweaver system I would get hold of the sapnwrfc library. (Google is your friend)
    It is designed to work with the new netweaver rfc interface.
    Cheers,
    Nigel

  • Installing SAPRFC PHP

    Greetings,
       I have seen the other post about the same subject but still finding it difficult to install SAPRFC, I have seen posts on project home page as well ( about the same problem ) which are still unanswered.
       I am trying to install version 1.3.3 (latest), my PC has SAP GUI 6.40 and librfc32.dll in in c:\windows\system32. My extension directory on php.ini is correct because mysql extension is loading from there. But when I add the line extension=php_saprfc.dll I get error "Unable to load dynamic link library c:\php\ext\php_saprfc.dll". I have tried it on Windows XP and WINDOWS 2000 Server.
      Craig others please share your experience or the platform used for installing saprfc.
    Regards,
    Sanjeev

    Hi,
    I too am facing a similar problem.
    I have <i>SAP GUI 640 for windows</i> installed.
    I have Installed <i>Apache/2.0.54</i> (Win32)
    I have <i>PHP/5.0.4</i>
    I am trying to install <i>SAPRFC 1.3-4.3.2</i>
    I have added the the extension in the directory 'ext' under PHP directory, which is specified as the extension directory.
    I have added '<i>extension=php_saprfc.dll</i>' in php.ini file
    But when I start Apache server I get the message
    '<b>PHP Startup: Unable to load dynamic library 'C:\PHP\ext\php_saprfc.dll' - The specified module could not be found</b>.
    This popup appears  twice.
    But the file php_saprfc.dll exists under that directory !!

  • How to get SAPRFC working on XAMPP 1.6.2? Try this.

    Hi
    I have just managed to get SAPRFC working with XAMPP 1.6.2 (released on  29/05/2007). I noticed there was not much information on XAMPP in the PHP Development forum, so thought this might be useful for anyone who may wish to use it.
    I originally started with Craig Cmehil's post <a href="/people/sap.user72/blog/2005/05/15/getting-started-with-php started with PHP</a>. I already had XAMPP installed, so just needed to update it and add SAPRFC support.
    I am using the following:
    Windows XP SP2
    XAMPP 1.6.2 - <a href="http://www.apachefriends.org/en/xampp-windows.html">http://www.apachefriends.org/en/xampp-windows.html</a>
    This includes:
    1. Apache 2.2.4
    2. MySQL 5.0.41
    3. PHP 5.2.2 + 4.4.7 + PEAR + Switch
    4. And other modules included. See XAMPP website for more information on the extra modules included.
    SAPRFC  1.4-5.20 - Re: PHP 5.2 and saprfc 1.4.1. This provided me with a link to SAPRFC 1.4-5.2.0. Using the php_saprfc.dll file included in this ZIP file solved the problem.
    <u>Instructions</u>
    1. Install XAMPP and follow setup taking defaults (I installed to C:\DEV\XAMPP)
    2. Extract SAPRFC to a suitable location (e.g. C:\DEV\SAPRFC)
    3. Copy the php_saprfc.dll file to the XAMPP\PHP\EXT folder (as defined in the extensions_dir in PHP.INI).
    4. Copy the remainder of the SAPRFC ZIP file to the XAMPP\HTDOCS folder. Create subdirectory if required.
    4. Edit PHP.INI and add the line <i>extensions=php_saprfc.dll</i> You will need to add this after the last <i>extensions=<some_extension>.dll</i> line.
    5. Shutdown and restart Apache using the XAMPP Control.
    6. Launch Internet Explorer and go to page <i>http://localhost/saprfc_test.php</i> or if you have put the SAPRFC PHP files in a subdirectory go to <i>http://localhost/yoursubdirectory/saprfc_test.php</i>.
    7. By running the saprfc_test.php file you should see a logon page.
    It should now be working on the PHP 5.2.2. I have not tested with the 4.4.7 version.
    That's all you need to do, so you should now be able to test some of the examples that are in the Blogs.
    Best of luck
    Nick

    Hello everybody,
    I've found simple solution for all problems with "Generate Activation Context failed for  ... php_saprfc.dll". This has something to do with missing libraries at your system.
    The next trace in Event viewer -> System was:
    "Dependent Assembly Microsoft.VC80.CRT could not be found and Last Error was The referenced assembly is not installed on your system.
    The solution is install: Microsoft Visual C++ 2005 Redistributable Package (x86)
    "vcredist_x86.exe" available at Microsoft downloads page.
    Good luck
    Michal.

  • How to get system time and date with PHP

    Dear Mr.Craig,
      Thanx a lot. We are running SRM 5.0 (RAMP - Implementation).
      My initial requirement is to write a server-side script to display server date and time. Could you give more inside on how to achieve it?
    Regards,
    Deva.

    Perhaps that will help.
    [code]
    <html>
    <h1>Access System time and date</h1>
    <?
         // saprfc-class-library     
         require_once("saprfc.php");
         $sap = new saprfc(array(
       "logindata"=>array(
       "ASHOST"=>"localhost"          // application server
       ,"SYSNR"=>"00"                    // system number
          ,"CLIENT"=>"000"               // client
          ,"USER"=>"bcuser"               // user
          ,"PASSWD"=>"minisap"          // password
         ,"show_errors"=>false               // let class printout errors
         ,"debug"=>false)) ;                     // detailed debugging information
         $result=$sap->callFunction("MSS_GET_SY_DATE_TIME",
            array(     array("EXPORT","SAPTIME",array()),
               array("EXPORT","SAPDATE",array())));
         if ($sap->getStatus() == SAPRFC_OK) {
        echo "Time: ".$result["SAPTIME"];
        echo "<br>Date: ".$result["SAPDATE"];
        echo "<br>or<br>";
        echo "Server is showing: "
             .substr($result["SAPDATE"], 0, 4)
             ."-".substr($result["SAPDATE"], 4, 2)
             ."-".substr($result["SAPDATE"], 6, 2)
             ." and "
             .substr($result["SAPTIME"], 0, 2)
             .":".substr($result["SAPTIME"], 2, 2)
             .":".substr($result["SAPTIME"], 4, 2);
         } else {
              $sap->printStatus();
         $sap->logoff();
    ?>
    [/code]

  • New To SAP/PHP - Introduction

    Hey everybody,
    I'm glad to see such an active PHP development community here!
    I just wanted to introduce myself because I'll probably be hanging around here a lot.
    My company is on a fast-track implementation of SAP and I'm solely responsible for the web integration so customers can log into our e-store, purchase on-line, and receive item updates and invoice information dynamically on the web.
    Background: I've been developing PHP applications (intranet and extranet) for about 5 years now and work on the <a href="http://en.wikipedia.org/wiki/LAMP_%28software_bundle%29">LAMP</a> stack. I program on a 15" PowerBook G4 and my main development application (other than TextEdit!) is Dreamweaver 8.
    So I hope to get to know you all and hopefully I'll be able to contribute something here instead of just asking questions all the time!

    I'm working with some ABAP programmers to get custom RFC calls to do the things we need in-house, so i don't know much about the library of standard SAP BAPI RFC calls.
    I'm programming a custom class based on the <a href="http://saprfc.sourceforge.net/src/saprfc.phps">saprfc connection class</a> in php to retrieve all the information that we want in a easy to manipulate format. for display on our website.
    Is there anywhere in the Netweaver client or online documentation that lists all the remote enabled BAPIs and what they do?
    Unfortunately, this is my first experience with SAP so I'm still learning, but my PHP programming experience makes it pretty easy to pick up the RFC calls.

  • How does execute PHP Script from SAP?

    I've already installed SAPRFC and run SAP Function from PHP successfully. But failed when tried execute PHP script from SAP (SM59). Anyone can help me for a clear instruction for this problem?
    Thanks

    Hi Max,
    here is the Source:
    [code]
    #!/usr/bin/php -q
    <?php
    // SAPRFC - Server example
    // PHP server function RFC_READ_REPORT
    // Require: CGI version PHP, RFC destination defined in SAP R/3 (SM59)
    // http://saprfc.sourceforge.net
    // Interface definiton for RFC_READ_REPORT
    // (generated by saprfc.php - option Generate PHP)
       $DEF_RFC_READ_REPORT = array (
                             array (
                                     "name"=>"SYSTEM",
                                     "type"=>"EXPORT",
                                     "optional"=>"0",
                                     "def"=> array (
                                             array ("name"=>"","abap"=>"C","len"=>8,"dec"=>0)
                             array (
                                     "name"=>"TRDIR",
                                     "type"=>"EXPORT",
                                     "optional"=>"0",
                                     "def"=> array (
                                             array ("name"=>"NAME","abap"=>"C","len"=>40,"dec"=>0),
                                             array ("name"=>"SQLX","abap"=>"C","len"=>1,"dec"=>0),
                                             array ("name"=>"EDTX","abap"=>"C","len"=>1,"dec"=>0),
                                             array ("name"=>"VARCL","abap"=>"C","len"=>1,"dec"=>0),
                                             array ("name"=>"DBAPL","abap"=>"C","len"=>1,"dec"=>0),
                                             array ("name"=>"DBNA","abap"=>"C","len"=>2,"dec"=>0),
                                             array ("name"=>"CLAS","abap"=>"C","len"=>4,"dec"=>0),
                                             array ("name"=>"TYPE","abap"=>"C","len"=>3,"dec"=>0),
                                             array ("name"=>"OCCURS","abap"=>"C","len"=>1,"dec"=>0),
                                             array ("name"=>"SUBC","abap"=>"C","len"=>1,"dec"=>0),
                                             array ("name"=>"APPL","abap"=>"C","len"=>1,"dec"=>0),
                                             array ("name"=>"SECU","abap"=>"C","len"=>8,"dec"=>0),
                                             array ("name"=>"CNAM","abap"=>"C","len"=>12,"dec"=>0),
                                             array ("name"=>"CDAT","abap"=>"D","len"=>8,"dec"=>0),
                                             array ("name"=>"UNAM","abap"=>"C","len"=>12,"dec"=>0),
                                             array ("name"=>"UDAT","abap"=>"D","len"=>8,"dec"=>0),
                                             array ("name"=>"VERN","abap"=>"C","len"=>6,"dec"=>0),
                                             array ("name"=>"LEVL","abap"=>"C","len"=>4,"dec"=>0),
                                             array ("name"=>"RSTAT","abap"=>"C","len"=>1,"dec"=>0),
                                             array ("name"=>"RMAND","abap"=>"C","len"=>3,"dec"=>0),
                                             array ("name"=>"RLOAD","abap"=>"C","len"=>1,"dec"=>0),
                                             array ("name"=>"FIXPT","abap"=>"C","len"=>1,"dec"=>0),
                                             array ("name"=>"SSET","abap"=>"C","len"=>1,"dec"=>0),
                                             array ("name"=>"SDATE","abap"=>"D","len"=>8,"dec"=>0),
                                             array ("name"=>"STIME","abap"=>"C","len"=>6,"dec"=>0),
                                             array ("name"=>"IDATE","abap"=>"D","len"=>8,"dec"=>0),
                                             array ("name"=>"ITIME","abap"=>"C","len"=>6,"dec"=>0),
                                             array ("name"=>"LDBNAME","abap"=>"C","len"=>20,"dec"=>0)
                             array (
                                     "name"=>"PROGRAM",
                                     "type"=>"IMPORT",
                                     "optional"=>"0",
                                     "def"=> array (
                                             array ("name"=>"","abap"=>"C","len"=>40,"dec"=>0)
                             array (
                                     "name"=>"QTAB",
                                     "type"=>"TABLE",
                                     "optional"=>"0",
                                     "def"=> array (
                                             array ("name"=>"LINE","abap"=>"C","len"=>72,"dec"=>0)
    // Create list of PHP server functions
       $GLOBAL_FCE_LIST[RFC_READ_REPORT] = saprfc_function_define(0,"RFC_READ_REPORT",$DEF_RFC_READ_REPORT);
    // PHP server function
       function RFC_READ_REPORT ($fce)
           $REPORT = saprfc_server_import ($fce,"PROGRAM");
           saprfc_table_init ($fce,"QTAB");
           $fd = fopen ($REPORT,"r");
           if (!$fd)
               return ("NOTFOUND");     // raise exception "NOTFOUND"
           while (!feof($fd))
               $LINE = fgets ($fd,73);
               saprfc_table_append ($fce,"QTAB",array("LINE"=>$LINE));
           fclose ($fd);
           saprfc_server_export ($fce,"SYSTEM","PHP");
           return (true);
    // Call script with: ./server.php -a phpgw -g hostname -x sapgw00
       $rfc = saprfc_server_accept ($argv);
    // Dispatch one function call
       $rc = saprfc_server_dispatch ($rfc,$GLOBAL_FCE_LIST);
       saprfc_close ($rfc);
    ?>
    [/code]
    Regards
    Gregor
    Message was edited by: Gregor Wolf

  • SAPRFC Installation

    Hi there.
    I've installed:
    PHP 5  in C:/Programme/XAMPP
    APACHE in C:/Programme/XAMPP and
    unzipped SAPRFC in C:/Programme/XAMPP/PHP/ext/rfcsdk.
    I've copied php_saprfc.dll into C:/Programme/XAMPP/PHP/ext and modified php.ini as below:
    extension_dir = "C:\Programme\xampp\php\ext\"
    extension=php_saprfc.dll
    I've no problem with SAPGUI and PHP itself.
    But I got following error:
    Message: This script use SAPRFC extension module for PHP and the extension isn't loaded. If you have already the extension compiled and installed, check your php.ini configuration.
    I've tried to follow the install instructions from SAPRFC. Is it possible that SAPRFC hat some problem with PHP-Location under XAMPP?
    Thanks in adv.
    sumiya

    Hi,
    I have checked the user authorizations. My user has SAP_ALL and is authorized to call/perform BSP-Applications and RFC-Functions.
    I have tested on sap-system the function SO_USER_LIST_READ and it shows me more than 200 users.
    Then I switched on tracing (ST01) and called my PHP-application, but there is no entries in the tracelist.
    I modified example_userlist.php a little bit and inserted echo-commands giving out messages after every function. It seems, it doesn't even reach the SAP-System. I got only the first message "create saprfc", that I put after creating saprfc.
    I would be very appriciated if you could have a look at the following codes:
    <html>
    <h1>SAPRFC-Class: Get List of Users in SAP-System</h1>
    <?php
         require_once("saprfc/saprfc.php");
         $sap = new saprfc(array(
                                  "logindata"=>array(
                                       "ASHOST"=>"myhost"     // application server
                                       ,"SYSNR"=>"00"          // system number
                                       ,"CLIENT"=>"420"     // client
                                       ,"USER"=>"AGOMBOJAV"     // user
                                       ,"PASSWD"=>"mypasswd"     // password )
                                  ,"show_errors"=>false                         ,"debug"=>false)) ;
        echo '<p>create saprfc</p>';
         $result=$sap->callFunction("SO_USER_LIST_READ",
                                            array(     array("IMPORT","USER_GENERIC_NAME","*"),
                                                      array("TABLE","USER_DISPLAY_TAB",array())
         echo '<p>call function</p>';               
         if ($sap->getStatus() == SAPRFC_OK) {
              echo '<p>Yes, print Userlist</p>';
              ?><table>
                   <tr><td>SAP-Name</td><td>User-Nummer</td></tr><?
              foreach ($result["USER_DISPLAY_TAB"] as $user) {
                   echo "<tr><td>", $user["SAPNAM"],"</td><td>",$user["USRNO"],"</td></tr>";
              ?></table><?
         } else {
             echo '<p>No, print Error</p>';
              $sap->printStatus();
         echo '<p>Logoff/Close </p>';
         $sap->logoff();
    ?>
    Is there anyway of debugging of php-applications in SAP-System?
    thanks and regards,
    sumiya

  • PHP problem - saprfc_test.php

    Question to the experts
    I just installed Apache 2.2.4 with PHP 5.2.1 and saprfc-1.4-5.2.0.Win32.zip ( I had could not use saprfc-1.4.1-5.1.1.Win32 due to incompatibility)
    Now everytime I run one of the test pages I get
    SAPRFC-Class: Get List of Users in SAP-System
    array( "ASHOST"=>"iwdfvm1035.wdf.sap.corp" // application server ,"SYSNR"=>"00" // system number ,"CLIENT"=>"100" // client ,"USER"=>"DEMO" // user ,"PASSWD"=>"WELCOME" // password ) ,"show_errors"=>false // let class printout errors ..
    I get a similar source code comming from the PHP from other test pages
    ANY Ideas?
    All phps are located under c:\apache22\htdocs
    Here is my config
    php.ini
      doc_root = "c:\apache22\htdocs"
      extension_dir = "c:\apache22\php\ext"
      extension=php_saprfc.dll
    The php_saprfc.dll is is in the ext directory and librfc32.dll is also under windows/system32
    saprfc.php is located in c:\apache22\htdocs
    Your help will be appreciated

    for apache you'll need <b>at least</b> something like:
    ScriptAlias /php/ "c:/path/to/php/"
    AddType application/x-httpd-php .php .php5
    Action application/x-httpd-php "/php/php-cgi.exe"
    if you used the cgi version of PHP.

  • Cannot locate Non-Unicode SAP RFCSDK 6.20

    Hi,
    I downloaded saprfc-1.4.1-5.2.2 and Installed PHP 5.2.2, I then went to download on-Unicode SAP RFCSDK 6.20 for my platform (Windows XP, or I can use 2000/2003 server 32bit if I need to)
    So I went to download SAP RFC SDK but its not there ?!?
    Support Packages and Patches - My Company's Application Components- SAP WEB AS - SAP WEB AS 6.20 - SAP RFC SDK>)   "No Data Available"
    Under 6.40 I can see some exist but only for IA64 etc and the saprfc php connector notes tell me to use 6.20.  Did anybody else have this problem? Can somebody do me a favour and e-mail me this file?
    Many thanks
    Rob
    rob.arundel AT freecom.com

    Hi Again,
    I have SAP GUI 6.40 installed on my PC and so it seems I did not need the SDK, its all working now;o)
    Now that testing has worked I am now planning on doing this from a Linux box without the GUI installed so will I now need the SDK? Where can it be obtained from?
    Many thanks
    Rob

  • PHP 5.2.2 AND SAPRFC 1.4.1 5.2.2

    Hello,
    i know, the same question i can find often in that Forum,
    but no answer will work on my system.
    <b><u>My Problem:</u></b>
    The "<i>php_saprfc.dll</i>" will not load.
    If i check with <i>extension_loaded ("saprfc")</i>, nothing will return. Also phpinfo shows me, that the DLL isnt loaded.
    Since three days i read in Forums and tried so many suggestions, but nothing will work.
    <b><u>System:</u></b>
    Webserver: IIS 6.0
    Operation System: Win 2003
    PHP Version: 5.2.2
    SAPRFC Version: 1.4.1-5.2.2
    SAPgui <b>not</b> installed, but <i>librfc32.dll</i> in "<i>/system32</i>" and registered by using <i>regsvr32 librfc32.dll</i>
    Version 6206.6.1761 (file info)
    Note: I got the DLL from our SAP-Team
    Dependency proofed with <i>Dependency Walker</i> one file missing: "<i>drvadodb.dll</i>
    Extension-Root located under "{<i>php-root</i>}/ext" (proofed with phpinfo)
    <i>php_saprfc.dll</i> file exists in Extension Folder
    in php.ini "<i>extension=php_saprfc.dll</i>" entered
    Note: all (exept one) defined extensions were loaded (proofed with phpinfo)
    IIS reset and also reboot of the System
    Note: Even the connection to the MS SQL database works proper
    I hope on your help and thanks for your efforts in advance!
    Matthias
    P.S.:
    Please, if it is possible do not send me link, because i have read all the links posted in this Forum. (and tried the suggestions)
    Message was edited by:
            Matthias Knopf

    Hello Matthias,
    I run into the same problem, my system:
    Web server: IIS 6.0
    Operation System: Win 2003
    PHP Version: 4.4.2
    SAPRFC Version: saprfc-1.4.1-4.4.1.Win32
    I located the librfc32.dll under c:\windows (and also tried c:\windows\system32)
    On a Windows XP, it works for me fine. However, on the Win 2003 the php_saprfc.dll is not loaded.
    Did you manage to solve this issue?
    Thanks in advance,
    Roy

  • PHP 5.2 and saprfc 1.4.1

    Hey all,
    Has anyone tried hooking-up PHP 5.2 and saprfc 1.4.1?
    I tried but getting this error message when I restarted my apache 2.0.54 :
    <i>"<b>PHP Startup: saprfc: Unable to initialize module
    Module compiled with module API=20050922, debug=0, thread-safety=1
    PHP compiled with module API=20060613, debug=0, thread-safety=1
    These options need to match" </b></i>
    I thought it's probably caused by the fact the the DLL, php_saprfc.dll binaries provided from the sourceforge download of SAPRFC was compiled with PHP 5.1.1, and not PHP 5.2.  Is that right?
    So, I tried recompiling the binaries itself by following the instruction provided by the INSTALL instruction of saprfc. However the compilation fails with the following message:
    <i><b>"Error     1     fatal error C1083: Cannot open include file: 'zend_config.h': No such file or directory     c:\php-5.2.0\Zend\zend.h     (line)53"</b></i>
    Although looking at zend.h there's an if statement there that if it's WIN32 then look for zend_config.win32.h.  Check out the codes below:
    #ifdef ZEND_WIN32
    # include "zend_config.w32.h"
    # define ZEND_PATHS_SEPARATOR          ';'
    #elif defined(NETWARE)
    # include <zend_config.h>
    # define ZEND_PATHS_SEPARATOR          ';'
    #elif defined(__riscos__)
    # include <zend_config.h>
    # define ZEND_PATHS_SEPARATOR          ';'
    #else
    # include <zend_config.h>
    # define ZEND_PATHS_SEPARATOR          ':'
    #endif
    Anyone has any luck?  I've been wanted to check this out with my SAP 4.6B but hope you guys can help me out here.
    Thanks!!
    -Ed

    hello all,
    I'm very new to this.
    I'm using apache2.0 and php 5.3
    i followed http://downloads.sourceforge.net/saprfc/saprfc-1.4-5.2.0.Win32.zip
    to download saprfc extension, but the page is redirected to saparefc1.41.all.
    On that zip files i couldn't get the extension for me.
    If you have the extension saprfc for php 5 can you send it to me or tell me from where I can download.
    when i downloaded the saprfc.tar.zip  and used its dll file for php extension,
    but my Apache won't work and says that it needs php4ts.dll files.
    i think that that extension is for php 4. when i reverted its working.
    So please give me the location to download the saprfc extension for php5.3 or more. please feel free to contact me.
    Thanks in advance
    Xavier Emerson
    [email protected]

  • Help SAPRFC extension PHP 5.3.6 running on Windows 2008 R2, IIS webserver

    Dear all,
    Can any body help me? how to connect saprfc on php 5.3.6 and running in IIS webserver?
    thanks
    gofur

    Dear all,
    Can any body help me? how to connect saprfc on php 5.3.6 and running in IIS webserver?
    thanks
    gofur

  • Php 5.12 / Apache 2.054 / Saprfc 1.4.1 for php 5.1.1

    Hi Everybody,
    I am trying to install this sap connector.
    It's easy but no simple to find the good version running together.
    My configuration below :
    Windows XP Pro SP2
    IIS 5.1 on port 80
    Apache 2.054 on port 8080
    Php 5.12
    Saprfc 1.4.1 for php 5.1.1
    I use the binaries distributions for each product.
    I have no issue, i hope, to load php_saprfc.dll module: i have no error message when Apache is starting.
    The test file index.php is running nice and display the environment to screen, BUT I DON'T FIND SAPRFC MODULE.
    If some of you have a idea, thanks for your help.
    If its usefull i have no issue to send us my files httpd.conf and php.ini.
    Best Regards
    Georges FREROT

    Hi Everybody,
    I want test the connector saprfc with php on two technical environments bellow:
    - Windows XP SP2 Professional, IIS 5.1, php 5.11 or 512
    - Windows XP SP2 Professional, Apache 2.054, php 5.11 or 512
    Windows XP is running on C: .
    IIS 5.1 is running on port 80, and Apache 2.054 on port 8080.
    I have build a development workspace on H: .
    The directory tree has this structure:
    H
    Apache2054
    Apache2
    Php511
    ext
    sessions
    includes
    Php512
    ext
    sessions
    includes
    saprfc141-511
    WebDev
    Sessions
    I have downloaded binaries of Apache 2.054, Php 5.11 and 512 and his Pecl 5.11 and 512 and Saprfc 141 511.
    I have uncompressed :
    Php 5.11 under H:\php511, 
    Pecl 5.11 under H:\php511\ext,
    Php 5.12 under H:\php512, 
    Pecl 5.12 under H:\php512\ext,
    Apache 2.054 under H:\Apache2054,
    SapRfc 1.4.1 5.1.1 under H:\saprfc141-511
    My first step is run php on IIS in isapi mode. It’s successful.
    The command localhost:80//Index.php display correctly echo phpinfo().
    My second step is install saprfc requirements:
    Copy:
    php_saprfc.dll in H:\Php511\ext
    php_saprfc.dll in H:\Php512\ext
    librfc32.dll up to date in C:\Windows\System32
    Verify msvcp60.dll up to date is in C:\Windows\System32.
    Modify php.ini:
    Include_path = “.;H:\Php511\includes;H:\Php511\pear”
    Extension_dir =”H:\Php511\ext”
    Include_path = “.;H:\Php512\includes;H:\Php512\pear”
    Extension_dir =”H:\Php512\ext”
    Extension=php_mbstring.dll
    Extension=php_gd2.dll
    Extension= php_saprfc.dll
    Extension=php_soap.dll
    Extension=php_mysql.dll
    To run php 5.11 or php 5.12 I modify the system path and configuration in WebServer 
    The results with php 5.11 are :
    With IIS 5.1 no loading error message, echo phpinfo() running nice, but no display the saprfc module.
    With APACHe 2.054 loading error message the same twice for php_saprfc.dll
    The results with php 5.12 are :
    With IIS 5.1 no loading error message, echo phpinfo() running nice, but no display the saprfc module.
    With APACHe 2.054 no loading error message, echo phpinfo() running nice, but no display the saprfc module
    If some of you have an idea what is wrong or forget at this point, thanks to help me.
    Bests Regards
    Georges FREROT

  • Saprfc version for php 5.2.1

    Hi all
      Can anyone pls tell me the version of saprfc to be installed for php version 5.2.1
    Thanks in advance

    The lastest version
    on the SAPRFC How to
    I assume you are using windows. If you are having hassles with getting it to work download a utility called <a href="http://www.dependencywalker.com/">dependency walker</a>.
    You can use this to check if the php_saprfc.dll is missing a dependency.
    I have been getting a dependency on DRVADODB.DLL on one particular machine and have had no joy resolving that yet.
    The other option is to grab a copy of Visual Studio Express Edition 2005 and compile it for yourself. Not for the fainthearted but I believe the force is strong with you.
    Hope this is useful,
    Nigel

Maybe you are looking for

  • Planned overhead is calculating wrongly in CK11N run, it is just more than double

    Hi Gurus 1) While running CK11N overhead cost is calculating wrongly on base (material price). In my case I have maintained 1% Overhead on raw material for Duty in cost sheet. In my case no routing, and my FG is getting produced by process order. My

  • Create Table Reagion Programatically

    Want to create table region programatically

  • Can't see recent pictures in Elements 11

    I uploaded pictures from my camera to Elements 11 and now I can't see them. They're in MyPictures folder and I can see them in Picasa. When I try to reload them from my hard drive I get Already in Catalog.

  • OOB feature in SharePoint 2013

    Hi Everyone Do we have any OOB SharePoint 2013 Feature for the below task or any OOB feature which almost performs/resembles the below task. 1) Reminders 2) Job Scheduling 3) To do list 4) Message inbox 5) Weather Forecast 6) Image Upload Regards Pra

  • Google Map3D object error

    Hello there. I'm trying to build my first Google Map application for Android using Burrito. I've found some code examples but I'm getting an error I don't understand.  I've downloaded/installed the Google SDK for Flex and I've Imported the map_1_20.s