|
What is the best practice method used when accessing
SAP Data through ODBC/ADO/OLEDB?
Or, even better with MS Excel or MS Access as I'm trying to get at a data source in SAP and integrate into office desktop applications. Answer: Using Microsoft Excel or Access to get to SAP data is not an issue as long as you're using standard (or created) remote function calls (RFC's). SAP Business Application Programming Interfaces (BAPIs) are just programs that will retrieve data when called. I would not encourage you to go against native SAP tables; all access should be controlled by RFC to avoid page faults and ensure you have the latest copy of the data you're requesting. Your programmers can make an RFC out of an existing program if it's not an RFC already. You will need some of the "References" available for Access that refer to SAP. There are a couple of things. You have to have a user ID and password for the SAP instance you want to access, and that ID has to have the clearance to not only get to the data in question, but it also has to be able to have RFC access. The calls in Access are not difficult once you get the hang of what the RFC/BAPI wants as input, as well as what it's going to hand you back as output. Here is a small example in Access VBA as to how you would establish the connection to SAP: Dim functionCtrl as Object Dim sapConnection as Object Dim theFunc as Object Dim returnFunc as Integer ' Set functionCtrl = CreateObject("SAP.Functions") set sapConnection = functionCtrl.Connection ' sapConnection.User = "your user ID" sapConnection.Password = "your password" sapConnection.System = "your system ID" sapConnection.ApplicationServer = "your application server" sapConnection.Client = "your client" sapConnection.Language = "your language"
If sapConnection.Logon(0,True) <> True then MsgBox "No Connection to R/3!" exit sub End If Set theFunc = functionCtrl.Add("name of the BAPI here") From here on, you need to understand exactly what the BAPI is calling for as inputs and outputs to it and set up variables, arrays, whatever you need to satisfy the requirement. Then, call the BAPI: returnFunc = theFunc.call If that doesn't return true, then it failed. Once the BAPI does its return, you read the results as
you would in any programming language, looping through the output.
How To Get Data From SAP To MS Access With Winshuttle? I've seen some reviews on the WInshuttle product but how easy is this to create nightly jobs to drop off a txt file? Is WinShuttle a program that sits on client side or is it a Server Tool administered by IT? Also, is there an additional licensed needed for WinShuttle? Answer: As for Winshuttle, that's a great product that can be used to extract data, or, to create spreadsheets that can be uploaded into many of the modules of SAP. Winshuttle can be both. It depends on your needs. It comes in different flavors, allowing you to have a user license that can't modify procedures, or a user plus a modifier or an admin with all rights. Yes, it can be maintained by IT, but it's also meant to be utilized by super-users who have IT savvy, as well as those who just want the answer without knowing all the underpinnings. You should get in touch with a Winshuttle representative and they could probably help you with more information. When it comes to the BAPI world, you'll just need someone on the SAP side to work with you on what's available and what the inputs/outputs are to the process. |
|
See Also Get help for your ABAP problemsDo you have a ABAP Question? ABAP Books
More ABAP Tips
SAP ERP Modules, Basis, ABAP and Other IMG Stuff All the site contents are Copyright © www.erpgreat.com
and the content authors. All rights reserved.
|