Skip to Content
0
Former Member
Nov 08, 2005 at 11:35 PM

Get Name for CO Cost Center Group and BGD Processing

81 Views

Hi,

I use these function modules to get the cost center group nodes in the CO hierarchy.

If I pass it a value that is in two controlling areas

if prompts another screen to pick which controlling area we want to look in. My problem is when I try to run this report in the background it gets hung up on this screen waiting for input. any ideas on how to get around this.

here is the reference code.

thanks

  • Please note that the following logic is parts of SAP example report

  • RGSEX001.

*----


  • Get the internal Set-ID from the external name of the set

  • Selection of sets can be restricted to a specific set class or

  • to sets matching a specific table field.

  • See documentation of function module G_SET_GET_ID_FROM_NAME

  • If the set class, subclass and setname is known, function module

  • G_SET_ENCRYPT_SETID should be used alternatively (see RGSEX020)

*----


CALL FUNCTION 'G_SET_GET_ID_FROM_NAME'

EXPORTING

shortname = w_set

old_setid = w_setid

IMPORTING

new_setid = w_setid.

*----


  • Read the complete hierarchy (set and all subsets)

*----


CALL FUNCTION 'G_SET_TREE_IMPORT'

EXPORTING

setid = w_setid "Set-ID, not the Setname!!!

no_table_buffering = ' '

TABLES

set_hierarchy = it_hierarchy

set_values = it_values.