Standardized ERP export format for invoices? - sap

Does anybody know if there is an open/standardized file format for exporting invoices from ERP systems? I am not even sure if that is possible, but I'd like to know nonetheless.
Except for the vague SAP/ERP export file format? item I couldn't find much useful information.
Is perhaps EDI supported for such things?

SAP uses its Idoc format to export business docouments. Idocs are essentially flat files, containing different segments with any number of fields. For invoices the standard idoc type is INVOIC01. To export a document as an Idoc you setup a message (the default invoice message is RD00) with output mode "EDI" and configure your SAP system to for instance save it on the file system (other options are available too, e.g. sending the Idoc to a RFC Server).
You can take a look at the Idoc definition using transaction WE60. You can also extend Idoc types, adding your own segments and fields to it.
as an addition: EDI is mostly used to send messages between business partners, for instance to send an invoice to the payer. Most ERP systems seem to be able to export documents so that an EDI system can create EDI messages from them, but they mostly don't support EDI messages themselves. They usually need that EDI mapping system as a translator between sender and receiver (actually 2 EDI systems, one operated by the sender, the other by the receiver).

Related

Configure .eds file to map channels of a CANopen Client PLC

In Order use a PLC as a Client (formerly “Slave”), one has to configure the PDO channels, since the default values of the manufacturer are often not suitable. In my case, I need the PDOs so send INT valued instead of the default UNSIGNED8 (see. Picture).
Therefore my question: What kind of workflow would you recommend, to map the CANopen Client PDO channels?
I found the following workflow suitable, however I appreciate any improvements and recommendations from your side!
Start by locating the .eds file from the manufacturer. The image show this in the B&R Automation Studio Programming Environment
Open the file in a eds. Editor. I found the free Vector CANEds Editor very useful. Delete all RxPODs and RxPDO mappings that you don’t need.
Assign the needed Data Type (e.g. INTEGER16) and Channel Name (“1 Byte In (1)”).
Add the necessary PDOs and PDO mapping from the database. (This might actually be a bug, but if you just edit the PDOs without deleting and recreating them, I always receive error messages)
Map the Date to the Channels
Don't forget to write the number of channels in the first entry (in this image: 1601sub0)
Check the eds file for Errors (press F5) and copy&paste the eds file to the original location point 1.)
Add the PLC Client device in Automation Studio and you should see the correct mappings.
(PS: I couldn't make the images smaller ... any recommendations about formating this question are welcome!)

Is there any object-storage standardized protocol for storing data+metadata?

When it comes to query databases, you can rely on SQL or when exchanging emails you can rely on SMTP.
They are both standards across vendors. We could generalize this to many other "standardized services".
This allows the backing provider of the service to be switched easily. I can change a local MySQL to a managed one, or I can switch an SMTP by another just changing the config of the application without changing the code.
Question:
When it comes to "store binaries", like for example say a company that needs to store photos sent by users, PDFs sent by providers and phone-call recordings from the quality department...
...when it's about "storing binaries over the net" is there any industry-standard in the form of "key-value-metadata" where the value is the binary, the metadata is a free-object (with possibly info about creation time, who is the creator, context of the creation, etc); and the ID is a function of the content (for example a Sha1 or whatever), that ensures anti-duplication measures by design?
When I say industry-standard I mean that I don't care if "behind" my connecting API, the "real" storage is implemented by a redis or a mysql or a plain-file-system or an S3 from AWS... just something "standard" given by multiple parties, to where I connect to and I can "easily change what's behind" by configuration and change from one storage-provider to another with the same simplicity we change our SMTP for example not caring if there's a sendmail or a postfix behind.

Old ABAP code still active for PyRFC even after TR was imported. Why?

I changed an ABAP RFC module in a SAP system X and transported the changes the Y. Now when I call the RFC SAP stills executes the old code.
I compared both versions from X and Y with a diff tool and found no differences, so it looks like the changes where transported. Is there a special step needed to activate my ABAP RFC code?
I use PyRFC as a client library.
We had the same problem with one of our RFC FMs. Reason was that the connection remained open once it was established. In this case, the binaries are not refreshed in the RFC context. Simply restart the connection and everything should work as desired.
This is a known issue: https://github.com/SAP/PyRFC/issues/89
Quoting the issue:
After the Python script ended, the connection should be automatically
closed and SAP NW RFC SDK initialised. Here what happens under the
hub.
Python interpreters and PyRFC instances share the same SAP NW RFC SDK
lib instance and when the remote enabled function module (RFM) is
called for the 1st time, the RFM metadata are cached inside SAP NW RFC
SDK. When the 2nd call of the same RFM requested from Python/PyRFC,
the SAP NW RFC SDK returns the metadata from cache, rather than
reading again from ABAP system, saving one Python/ABAP roundtrip and
some performance, especially in case of complex RFMs. If the RFM
signature changed in the meantime, the cached RFM metadata are not
changed and Python "sees" the old ABAP code.
I hope a developer friendly solution will get used for the future.
There is no need for activating anything. It should be fine as you transport it.
You can try these;
Transport everything again.(Including other tasks of the same request)
Check the destination field in your call to see if you are calling the correct system
Clear the buffer => TCode /$sync

SAP missing file

I am integrating a BizTalk application with SAP. I get an error when SAP sends me some data because the required schema is not declared in BizTalk.
The required schema is http://Microsoft.LobServices.Sap/2007/03/Types/Idoc/3/ZCREMAS01//700
I can find this schema in SAP (when consuming an adapter service from BizTalk), but it does not contain the segment E2LFM1M005.
The error I get is
The adapter "WCF-Custom" raised an error message. Details
"Microsoft.ServiceModel.Channels.Common.XmlReaderGenerationException:
The segment or group definition E2LFM1M005 was not found in the IDoc
metadata. The UniqueId of the IDoc type is: IDOCTYP/3/ZCREMAS01//700.
For Receive operations, the SAP adapter does not support unreleased
segments.
Can you tell me where can I find this iDoc definition?
The SAP release when it comes to idocs can be a bit tricky. In your case, your SAP system will probably be in a higher version then 700.
There are 2 things that you can change.
In your SAP receive location, go to the "Binding" tab in the settings and check the "ReceiveIdocRelease" parameter. There should be a syntax hint on the bottom.
In SAP go to WE20 and check the specific LS, KU, ... you are using. If you edit the idoc type you want to change there, you can see on the bottom a field where you can specify a segment release. Put 700 here and try again.
I can't really make screenshots now. If it's not clear, let me know. I'll post a more complete answer next week.
Kind Regards
Tim

Using search help for different system?

I need a search help for my bukrs field. The problem is data should come from different system. There are 2 systems like X and Y. i am in X system and running a program.
At selection screen bukrs field exists. When i click on search help data should come from system Y.
I heard that it is possible to pull data to search help but couldn't find enough info in sites.
Best Regards.
5 month experienced with SAP/ABAP :)
To create a search help with a custom data selection, you can define a search-help exit in your search help. To select data in a custom way and not from a database table, go to the tab "Definition" of the search help, remove the content of the input "Selection Method" and enter a function module into the input "Search help exit". This function module must have the same signature as the example module F4IF_SHLP_EXIT_EXAMPLE. The comments in the sourcecode of this example module will explain you how to implement it. Your implementation of this function module can then perform the data acquisition from another system with a remote function call.
To get data from another system, you have to call a function module in a remote system via RFC (remote function call). To do this you need:
the RFC-capable function module in the remote system which exports the data you need. You can set a tick on the properties tab of a function module to make it RFC-capable.
An RFC connection from the local system to the remote system. RFC destinations can be created and configured with the transaction SM59.
To call a function module via RFC, you just have to add DESTINATION [rfc-destination] to the function call.
CALL FUNCTION 'Z_YOUR_RFC_CAPABLE_FUNCTION_MODULE'
DESTINATION 'my_rfc_destination'
IMPORTING [...]
The user will have to log into the remote system in order to call RFC function modules in it, unless you define a username with password in the RFC connection. When you do that, you should create a dedicated system user in the remote system with minimal permissions especially for this RFC connection. When the user has too wide permissions, the RFC connection can be abused for other purposes.