Interfacing S/4 HANA & Shipping Software( UPS WorldShip and FedEx Ship Manager) using ODBC
This blog post describes the Bi-Directional Linking of FedEx World Ship or UPS Shipping software without any 3rd Party Software or Cloud additions to HANA.
The following setup will allow the auto-population of the updated Shipping address, Carrier accounts, customer preferred shipping methods in the shipping software screen and the automatic export of the costs and Tracking info back to SAP Delivery document using plain old ODBC and some AMDP calls. The following process diagram illustrates the whole integration.
The integration depends on the creation of a Database User( Say SH_SHIPPER) with NO ACCESS TO ANY SAP TABLE in the main SAP Schema(SAPABAP1 for example) and thus isolated with no authority requirements as such. This database user should have ODBC Access and an un-expiring password.
Log in with this user and create two tables in the user schema ( Switch to the HANA Admin Console Perspective while creating these tables in ADT in Eclipse).
In the setup above, ZZ1_SHIPMENTS is a table to hold the Shipment Addresses, Account Numbers and Shipment preferences and ZZ1_SHIPMENT_VIEW is a Client Specific view that is exposed to the shipping software. The ZZ1_TRACK_SHIPMENTS is the table to hold the actual Tracking info and Costs for feeding back to delivery.
Once you create these tables you could simply export the SQL to recreate them in TST and PRD Landscapes. The ADT simplifies the table creation.
After this, while logged in as SH_SHIPPER we will need to grant permissions on SH_SHIPPER Schema to _SYS_REPO and SAP<SYS> ( eg SAPABAP1) with GRANT OPTION. This will allow the SAP<SYS> user to write and read from these tables.
On Delivery Create or Change, the LIKP Business Object events can be used to write or update the ZZ1_SHIPMENTS Table with up-to-date addresses and shipping conditions.
Shown below is AMDP Code snippet to write to the shipments table
Similarly, we will have to code an update function to read the ZZ1_TRACK_SHIPMENTS Table to read tracking and costs that can be invoked at goods issue or before PGI. This function will need to handle shipment deletions and multiple packages and the use of a Master tracking number.
Now the steps below show the actual integration on the shipping stations.
Install the Hana ODBC Installation on the Ship Station ( using SAP HANA CLIENT 2.0 refer https://launchpad.support.sap.com/#/notes/2811890) and then set up the System DSN for the HANA.
The server is the Hana Database IP and port usually 30015, please check with Basis.
Upgrade UPS and FedEx Stations to the latest versions and Check if the Integrations are active. FedEx/UPS Technical support will readily help you with this part.
Using the DSN connection, we are now ready to map and develop the Integrations. Once these are developed, we can easily port to other shipping stations by simply copying the Integration Profiles.
For FedEx, you can find the Integration editor under menu Integration and we can configure both import and export in the same profile.
In the UPS the Profile editor allows separates profiles for import and export.
ODBC debug tools are available within the Shipping software. For example, you can set up a debug log in the software to allow detailed logging. This will catch errors with data formatting or SQL read or write errors etc.
We went live recently with this setup and it is working great. This simplified the integration and also saved us on the licensing and maintenance costs if we had used a third-party solution.