I have to poll xml file from a network and invoke into business
connector before I send it to SAP.I use getFile service
to retrieve the file.But couldn’t get the service name to move
the file to SAP.Could you suggest one.
I am not sure what you are asking. What type of file is this? What will SAP do with this file once it gets it? Do your need to send the physical file to SAP (FTP), trigger a RFC, or send it via ALE as an IDOC?
If you provide more details, we could better help you.
Type of file - XML
SAP RFC should be triggered once the file is taken from network.
Also the file from network will be moved to Archive once it is passed to SAP.
I am looking for these services so that I can schedule them.
This is probably an oversimplified list of steps that you would need to handle getting the XML file contents to SAP.
In general it is important to note that the file is never physically sent to SAP and everything is done in-memory. You would probably use FTP or other customized Java code to work with the physical file (moving to Archive, deleting etc.) after processing the contents in SAP.
getFile - Retrieves the file from the file system in to BC as bytes.
pub.string:bytesToString - Converts bytes to a string.
stringToDocument - Parses the text string representing an XML document into a Document object (node).
pub.web:documentToRecord - Converts a parsed XML document(node) to an IData object(ordered key/value pairs representation of the XML in BC).
Map - Now you have elements and values of the XML data in the pipeline and you need to map the values from the Idata object to the inputs of the RFC(which you get from the “Function Signature”) that you want to call.
Invoke RFC - Call the RFC using the “Function Signature” that was created. See 2nd Note below on how to do this.
-I recommend you use the error handling techniques well described in the article http://www.wmusers.com/ezine/2002dec_iandrosov_1.shtml. You would put the list of services above in the try sequence.
-In order to trigger a RFC on SAP, you will need a “Function Signature” which you generate in the Administrator part of BC. Follow chapter 4 of the SAP adapter documentation as there are several steps to this. You’ll need a SAP alias and an outbound map of the RFC you intend to call in order to trigger an RFC on SAP.
Thanks very much Andrew.I will let you know how it goes!
I would like to call RFC or BAPI on SAP R/3 4.6.
I don’t understand how to call that in SAP BC Developper.
There are no samples.
The program must be in C language on HPUX11i.
Do you have the same that ?