Tuesday, May 13, 2014

Query To Display Security Rules Details in Genaral Ledger

SELECT fif.id_flex_name
      ,fifs.id_flex_structure_name
      ,ffksv.parent_segment_name
      ,ffvrv.flex_value_rule_name
      ,ffvrv.description
      ,ffvrv.error_message
      ,decode(ffvrl.include_exclude_indicator,'I','Include','E','Exclude')
      , ffvrl.flex_value_low
      ,ffvrl.flex_value_high
      ,fav.application_name
      ,frv.responsibility_name
      ,ffvrv2.flex_value_rule_name
  FROM fnd_id_flexs fif
      ,fnd_id_flex_structures_tl fifs
      ,fnd_flex_key_seg_vset_v ffksv
      ,fnd_flex_value_rules_vl ffvrv
      ,fnd_flex_value_rule_lines ffvrl
      ,fnd_flex_value_rule_usages ffvru
      ,fnd_application_vl fav
      ,fnd_responsibility_vl frv
      ,fnd_flex_value_rules_vl ffvrv2
 WHERE 1=1
   AND fif.id_flex_name='Accounting Flexfield'
   --AND fif.id_flex_number= fifs.id_flex_num
   AND fif.id_flex_code= fifs.id_flex_code
   AND ffksv.id_flex_name= fif.id_flex_name
   AND ffksv.id_flex_structure_name=fifs.id_flex_structure_name
   AND ffvrv.flex_value_set_id= ffksv.flex_value_set_id
   AND ffvrl.flex_value_set_id= ffksv.flex_value_set_id
   AND ffvrl.flex_value_rule_id= ffvrv.flex_value_rule_id
   AND ffvru.flex_value_set_id= ffksv.flex_value_set_id
   AND fav.application_id=ffvru.application_id
   AND frv.responsibility_id=ffvru.responsibility_id
   AND ffvrv2.flex_value_set_id=ffvru.flex_value_set_id

   AND ffvrv2.flex_value_rule_id=ffvru.flex_value_rule_id

No comments:

Post a Comment

Best Blogger TipsGet Flower Effect