SAP report of field status variant, in 4.7

Advertisement
Hello all,
Is there a SAP report that lists a field status variant, its groups, the groups fields, and the entry properties of the fields?
In customization, path  /Financial Accounting/Financial Accounting Global Settings/Document/Line Items/Controls/Maintain Field Status Variants - execute
Gets you to the transaction where this is set up.  If you have access to this transaction, you can see all of that information, even capture it to a spool or presentation file.
We want to give this information to users who don't have that access. 
I am hoping that someone knows of a SAP report with that information, or someone has already created their own report and is willing to share some code.
I started to look at function PREPARE_FIELD_SELECT_STRING, but got lost in the detail.  If that is only way to get what I want, well...
Thanks
Bruce
Advertisement

Replay

This is my solution.  Simple code, once I finished debugging the function module PREPARE_FIELD_SELECT_STRING.
tables: t004f,       " Field status definition groups
        tmodf,       " Groups in Field Selection Bar
        tmodg,       " Name of Groups in Field Selection Bar
        tmodo,       " Items in Field Selection Definitions
        tmodp.       " Name of Items in Field Selection Definitions
data: w_t004f type t004f.
data: i_t004f type table of t004f.
data: begin of gruptab occurs 0,
        ggrup   like tmodo-ggrup,
        ftext   like tmodp-ftext,
        xhell   type c,
      end of gruptab.
data: c500(500)    type c.
data: incoming_string(200).
data: fleng(4)     type n.
data: w_string_position(3) type n.
select-options: s_fstva for w_t004f-bukrs  default '0001'  obligatory.
selection-screen skip 1.
select-options: s_group for t004f-fstag default 'GT02'.
start-of-selection.
  select * from t004f into table i_t004f   "
           where bukrs in s_fstva
             and fstag in s_group.
  loop at i_t004f into w_t004f.          " field status groups (FSG)
    skip 1.
    write: / w_t004f-fstag.
    perform get_subgroup_list.
  endloop.                                                  " i_t004f
end-of-selection.
form get_subgroup_list .
  clear gruptab.  refresh gruptab.
  incoming_string        = w_t004f-faus1.
  incoming_string+90(50) = w_t004f-faus2.
  select * from tmodf where fauna = 'SKB1-FAUS1'.
    gruptab-ggrup = tmodf-ggrup.
    select single * from tmodg where spras = sy-langu
                               and   fauna = tmodf-fauna
                               and   ggrup = tmodf-ggrup.
    if sy-subrc = 0.
      gruptab-ftext = tmodg-ftext.
    else.
      gruptab-ftext = text-ngg.
    endif.
    append gruptab.
    skip 1.
    write: /5 gruptab-ftext,
           50 'Suppress',
           60 'Required',
           70 'Optional'.
    perform get_fields.
  endselect.  "  FROM tmodf
endform.
form get_fields .
* ------- Read the item texts
  select * from tmodo where fauna = 'SKB1-FAUS1'
                        and ggrup = tmodf-ggrup.
    select single * from tmodp where spras = sy-langu
                               and   fauna = tmodo-fauna
                               and   modif = tmodo-modif.
    write: /10 tmodp-ftext.
* get individual field options
    write tmodp-modif to w_string_position.
    w_string_position = w_string_position - 1.
    case incoming_string+w_string_position(1).
      when '+'.
        write: 60 'X'.             " obligatory
      when '.'.
        write: 70 'X'.             " optional.
      when '-'.
        write: 50 'X'.             " supress
    endcase.
  endselect.  " FROM tmodp
endform.
Edited by: Bruce Tjosvold on Jun 30, 2011 7:17 PM