SQL query to get custom top location in Oracle Apps


Each application has its assigned top in oracle apps. That top points to a location. For example, run the following query to get the basepath (top_name) assigned to application (Accounts Payable in our case):


select 
      a.application_id,
      a.application_short_name,
      a.basepath,
      a.product_code,
      b.application_name
from 
      fnd_application a,
      fnd_application_tl b 
where 
      a.application_id            = b.application_id
      AND application_short_name  = 'SQLAP';



Now just run the below query to get the top location, if you know the custom top name, just replace top_name (AP_TOP here)  and then you will be able to get its location

SELECT  distinct 
      variable_name top_name, 
      value top_location
from 
      fnd_env_context a
where 
      variable_name ='AP_TOP'; --AP_TOP is our basepath or top_name


Comments