2012年11月4日 星期日

會科查詢 sql, chart of account




SELECT a.segment_name,
        c.flex_value,
        d.description,
        a.application_column_name,
        c.parent_flex_value_low,
        a.segment_num,
        a.display_flag,
        a.display_size,
        a.maximum_description_len,
        a.concatenation_description_len,
        e.set_of_books_id
 FROM   applsys.fnd_id_flex_segments a,
        applsys.fnd_flex_values c,
        applsys.fnd_flex_values_tl d,
        gl_sets_of_books e
 WHERE  a.flex_value_set_id = c.flex_value_set_id
 AND    a.application_id = 101
 AND    a.id_flex_code = 'GL#'
 AND    c.flex_value_id = d.flex_value_id
 AND    d.LANGUAGE = USERENV('LANG')
 AND    e.set_of_books_id = :ledger_ID
 AND    e.chart_of_accounts_id = a.id_flex_num;

沒有留言:

張貼留言