Sunday, 16 June 2019

Query to get Flexfield Prompts using table name

Query to get Flexfield Prompts


SELECT params.application_id,
       params.descriptive_flexfield_name,
       params.descriptive_flex_context_code,
       params.application_column_name,
       params.end_user_column_name,
       params.form_left_prompt,
       params.description,
       params.column_seq_num,
       dflx.APPLICATION_TABLE_NAME,
       params.required_flag,
       params.enabled_flag,
       params.display_flag,
       params.display_size,
       params.flex_value_set_id
  FROM apps.FND_DESCR_FLEX_COL_USAGE_VL  params,
       apps.FND_DESCRIPTIVE_FLEXS_vl     dflx
 WHERE     1 = 1
       --and params.descriptive_flexfield_name  like 'Global%'
       --and upper(params.form_left_prompt)  upper('%Name%')
       AND dflx.application_id = params.application_id
       AND dflx.application_table_name = UPPER ('ra_customer_trx_lines_all')
       --AND params.descriptive_flex_context_code='RA_CUSTOMER_TRX_LINES'
       --and params.application_column_name='ATTRIBUTE6'
       --And application_column_name='ATTRIBUTE5'
       AND params.DESCRIPTIVE_FLEXFIELD_NAME =
           dflx.DESCRIPTIVE_FLEXFIELD_NAME;
/