0 Replies Latest reply: Oct 8, 2013 2:18 PM by Sundeep.R Branched from an earlier discussion. RSS

    Re: REPORTING CURRENCY CODE COLUMN NOT PRESENT

    Sundeep.R

      Hi,

      Can any one please share the modified query after replacing the gl_mc_reporting_options table with the gl_ledger_relationships.

      I am using the below query, correct me if I am wrong

       

      select currency_code

      from gl_sets_of_books where set_of_books_id = fnd_profile.Value('GL_SET_OF_BKS_ID')

      and not exists

      (select 'x'

      from gl_ledger_relationships gmro1,

      gl_ledger_relationships gmro2

      where  gmro1.target_currency_code = gmro2.target_currency_code

      --OR gmro1.reporting_currency_code = gmro2.reporting_currency_code)

      and gmro1.target_ledger_category_code = gmro2.target_ledger_category_code

      and gmro1.target_ledger_category_code = 'ALC'

      and  gmro1.relationship_enabled_flag = gmro2.relationship_enabled_flag

      and gmro1.application_id = gmro2.application_id

      and gmro1.relationship_id <> gmro2.relationship_id

      and gmro1.relationship_enabled_flag = 'Y'

      and gmro1.application_id = 201

      and gmro1.primary_ledger_id = fnd_profile.Value('GL_SET_OF_BKS_ID')

      and gmro1.primary_ledger_id = gmro2.primary_ledger_id);

       

      Also I found out that there is an oracle standard view GL_ALC_LEDGER_RSHIPS_V available, but I am not sure if we can use that in the query.

       

      Thanks,

      Sundeep