SQL Command Editor in SAP

All QuestionsCategory: TutorialsSQL Command Editor in SAP
Profile photo of SAP guruSAP guru Staff asked 2 months ago

Sometimes there are situations when you need to select data from multiple tables, someone can immediately suggest using SAP Query, but we are not looking for easy ways, besides very often sappers become a nation that has passed rigorous database developers school, so SQL does not scare us.

SQL fans can use transaction ORA_PERF, certainly in productive it would be wrong, but you can play during the implementation.
So, we execute ORA_PERF transaction code, then select the menu item Additional Functions-> SQL Command Editor


For exapmple, let’s try this code:
select u.CUOBJ, u.OBTAB, a.ATINN, a.ATWRT AS result
from INOB u
ON u.cuobj = a.objek
where u.OBJEK=’*******************************’


AUSP – table for storing characteristic values (Specifications signs)
INOB – table for storage ligament configuration object and the system object
In the code, we do join two tables, and then select the characteristic values for the object, in my case it was the batch of material.
Hit F8 and waiting for the result: