Since I want to limit manual work as much as I can, I therefore use the SAP QuickViewer (transaction SQVI). This tool allows you to make a join and quick representation of data in minutes, but is also very, very legacy and does not include certain functions, like advanced joining or sorting upfront.
Luckily there is an alternative: using the SQL Console in Eclipse…
With this tool you can easily create and execute your own openSQL-queries from outside the SAP-environment (eg. by not using the SapGUI). The SQL-console has been widely used for selecting data for quite some time but since SAP has its own development environment I was used to developing with the ABAP-tools like the workbench (SE80). Therefore the SQL-console was a gem I never used.
Steps to make it happen
- Install Eclipse (I use Mars, but Neon will work too)
- Download and install from https://www.eclipse.org/downloads/
- Add the SAP Development tools in Eclipse
- Go to Window -> Preferences -> Install / Update (left side) -> Available Software Sites -> Add https://tools.hana.ondemand.com/mars
- Go to Help -> Install New software -> Work With (select the site added above) -> Select ABAP
- Development Tools for SAP Netweaver (I just select all since I like software)
- Create an ABAP project – necessary to make a connection to SAP (Netweaver)
- Go to New -> Project -> filter on ABAP -> ABAP project
- Choose the system to connect to (these are the entries in your saplogon.ini)
- Next -> All details are taken from your saplogon.ini
- Fill in your username / password -> click finish
Now you should have a connection in your development environment that looks like this:
ResultsRightclick on the connection and click on SQL Console. Two panes open on the right side of the connection, showing an input field for your SQL-query and an output field for the results:
Fill in your query and press 'Run'!
In the example I used, you can see in the subscreen below the query, that the SQL-query I used actually produced generated code in SAP. The time it took the system to execute the query is also shown. By right clicking your project and selecting the option ‘Open in Project’ you can make a comparison between the query on you current project (eg. development system) and another system (eg. production). This way, you can see how your query performs per system.
Be awareTo execute a query in the SQL-console, your user needs to have the authorization object S_ADT_RES on the system you execute it.
(Luckily) only SELECT statements are allowed. This way, no dangerous inserts or updates can be executed.
The limitation of 5.000 results in earlier versions has been upscaled to 100.000 results. This may impact performance when retrieving your data