Network - subnetwork hierarchy using std networks.
I want to create network / subnetwork hierarchy using std. networks.
How is it done in PS.
Create standard Network > Create Activities in Standard Network > Assign Milestone in Std NW > Define Milestone functions/Parameters > Now with the help of this Std network number you can create Sub Network as you wants [In CN21 Transaction code input Std NW number then automatically system will create all subnetwork from that Std Network
Swapnil Kharul
Similar Messages
-
Not able to view Characteristic Hierarchy using Tcode KES3
Hi everyone,
I need to view the Characteristic Hierarchy using T-code KES3 in CO-PA. Ideally, once we are into KES3 screen, we need to select the characteristic and variant to display the hierarchy. But, when I select the characteristic and variant, it says that "Hierarchy doesn't exist".
However, when I create a report for that particular characteristic using T-code KE31, I am able to view the hierarchy for that characteristic there.
Can anyone please help me in this regard that why the characteristic hierarchy is not available in KES3, while it's picking up the hierarchy at the time of report creation.
Thanks.
Regards,
Gaurav TibrewalHi Nikolas,
I want to see the hierarchy of "Business Unit" characteristic. This characteristic is being maintained under "Referenced Characteristic" in T-code KE31. This characteristics is being maintained in Profitability Analysis (T-code KEA5).
Also, I am not able to derive the source where the hierarchy is being maintained for that characteristic. Because, if hierarchy is coming while creating CO-PA reports. they must be maintained somewhere.
Please let me know if you need any further input.
Regards,
Gaurav -
Building Tree hierarchy Using nested loops and class cl_gui_column_tree
Hello gurus,
I want to create a tree report using custom container and class cl_gui_column_tree. I have read and understood the standard demo report which SAP has provided i.e. SAPCOLUMN_TREE_CONTROL_DEMO. But in this report all the levels nodes are created as constants and hardcoded. I want to create hierarchy using nested loops. For this i took one example of a hierarchy of VBAK-VBELN->VBAP-POSNR Like One sales order has many line items and each line item can have number of line items in billing plan.
I have done some coding for it.
FORM build_tree USING node_table TYPE treev_ntab
item_table TYPE zitem_table. " i created the zitem_table table type of mtreeitm in SE11.
DATA: node TYPE treev_node,
item TYPE mtreeitm.
node-node_key = root.
CLEAR node-relatkey.
CLEAR node-relatship.
node-hidden = ' '.
node-disabled = ' '.
CLEAR node-n_image.
CLEAR node-exp_image.
node-isfolder = 'X'.
node-expander = 'X'.
APPEND node TO node_table.
item-node_key = root.
item-item_name = colm1.
item-class = cl_gui_column_tree=>item_class_text.
item-text = 'Root'.
APPEND item TO item_table.
item-node_key = root.
item-item_name = colm2.
item-class = cl_gui_column_tree=>item_class_text.
item-text = 'Amount'.
APPEND item TO item_table.
LOOP AT it_vbeln INTO wa_vbeln.
node-node_key = wa_vbeln-vbeln.
node-relatkey = root.
node-relatship = cl_gui_column_tree=>relat_last_child.
node-hidden = ' '.
node-disabled = ' '.
CLEAR node-n_image.
CLEAR node-exp_image.
node-isfolder = 'X'.
node-expander = 'X'.
APPEND node TO node_table.
item-node_key = wa_vbeln-vbeln.
item-item_name = colm1.
item-class = cl_gui_column_tree=>item_class_text.
item-text = wa_vbeln-vbeln.
APPEND item TO item_table.
item-node_key = wa_vbeln-vbeln.
item-item_name = colm2.
item-class = cl_gui_column_tree=>item_class_text.
item-text = wa_vbeln-netwr.
APPEND item TO item_table.
LOOP AT it_posnr INTO wa_posnr.
node-node_key = wa_posnr-posnr.
node-relatkey = wa_vbeln-vbeln.
node-relatship = cl_gui_column_tree=>relat_last_child.
node-hidden = ' '.
node-disabled = ' '.
CLEAR node-n_image.
CLEAR node-exp_image.
node-isfolder = ' '.
node-expander = ' '.
APPEND node TO node_table.
item-node_key = wa_posnr-posnr.
item-item_name = colm1.
item-class = cl_gui_column_tree=>item_class_text.
item-text = wa_posnr-posnr.
APPEND item TO item_table.
item-node_key = wa_posnr-posnr.
item-item_name = colm2.
item-class = cl_gui_column_tree=>item_class_text.
item-text = wa_posnr-netpr.
APPEND item TO item_table.
ENDLOOP.
ENDLOOP.
ENDFORM.
Now this program compiles fine and runs till there is only one level. That is root->vbeln. But when i add one more loop of it_posnr it gives me runtime error of message type 'X'. The problem i found was uniqueness of item-item_name as all the sales order have posnr = 0010. What could be done? I tried giving item_name unique hierarchy level using counters just like stufe field in prps eg. 10.10.10, 10.10.20,10.20.10,10.20.20,20.10.10 etc.. etc.. but still i am getting runtime error when i add one more hierarchy using nested loop. Plz guide.
Edited by: Yayati6260 on Jul 14, 2011 7:25 AMHello all,
Thanks the issue is solved. The node key was not getting a unique identification as nodekey. I resolved the issue by generating unique identification for each level. Thanks all,
Regards
Yayati Ekbote -
Unable to copy using std plng fun
Hi Expert,
I am trying to copy transaction data in same RTC using std copy planning function from 1 version to other version.
I hv checked the data in cube..... --- It's available.
I hv checked real time behaviour.---- Planning allowed.
Locking -
No locking conflicts.
Variable values entered during planning seq. execution -
evertything correct.
But, still it's not working properly..... Got 0 read, 0changed,0generated, 0deleted message.
I'm missing something ... Kindly correct me....
Thanks
ShamkantHi.
In planning function check "FROM" value.
If it is restricted by variable or hard-coded value may be this value not exist in the cube.
Also check filter.
If you have restriction by variables try to set hard coded values and chech whether is ok.
Regards. -
I have creatd smartform for vendor return invoice and i m using std zprog o
i have creatd smartform for vendor return invoice and i m using std zprog of other client and corresponding prog.. when i run this program using .....after creating transc in se93. is it not workin ..
where should i check for error and i am not getting selection screen in se38 program which i am using with this smartform..
can u tel me step wise....what is the procedure so i can run and execute and see my output..
please
regards.Hi,
when you run program from SE38 are you able to see the selection screen and able to exucute with out error....
And when you run the t-code which you created for your Z-prog whats the message its giving...
Regards,
Shankar. -
How to use std object RFBIBL00
Dear All,
For uploading open item of vendor and customer std lsmw RFBIBL00 is available.
I know how to do recording in lsmw for new object but any one can help how to use std lsmw available in SAP. For eg.RFBIBL00
Regards,
BhadreshYou'll find that the RFBIBL00 program, suprisingly, has extensive documentation attached - or you could try
http://help.sap.com/saphelp_45b/helpdata/en/35/a47e63763e0392e10000009b38f9b7/content.htm
or the print documentation at
help.sap.com/printdocu/core/Print46c/en/data/pdf/CAGTFADM/CAGTFADM-FI.pdf
cheers
Jonathan -
Is there possibility to add dimension value into hierarchy using dml or spl
1 Is there possibility to add dimension value into hierarchy using dml or spl?
If such possibility exists how to do that.
2 Is it possible to sort dimension values inside one branch of the hierarchy?What version of OLAP are you using and how did you create your AW (e.g., AWM)?
Assuming that you're used either AWM or the Java API for AWs in 10g, there isn't an OLAP DML for adding a dimension member to a dimension (and have all the meta data kept in sync); you must load dimension members using AWM the Java API for AWs.
So, make your changes in the the dimension table and process that table.
For sorting, you can add a sort attribute to the dimension. Add the sort attribute to the model, indicate that it's used for sorting, add the sort attribute to your dimension table and maintain the dimension. -
Hi all,
I have developed a program for ALV Tree Hierarchy using OOPs.I followed the SAP demo program.I am not able to get the values in the output.Please can anyone guide me where to correct my program. I am placing the entire code so that you all can also debug and see what is wrong.
*& Report ZZHIERARCHY_TEST1
REPORT zzhierarchy_test1.
DATA : alv_container TYPE REF TO cl_gui_custom_container,
alv_tree TYPE REF TO cl_gui_alv_tree,
gt_fcat TYPE lvc_t_fcat,
gt_vbrk TYPE vbrk OCCURS 0. "Output Table
DATA : gs_hirarchy_header TYPE treev_hhdr.
START-OF-SELECTION.
END-OF-SELECTION.
CALL SCREEN 9100.
*& Module STATUS_9100 OUTPUT
MODULE status_9100 OUTPUT.
SET PF-STATUS 'ALV_TREE'.
IF alv_container IS INITIAL.
PERFORM tree_dev.
ENDIF.
ENDMODULE. " STATUS_9100 OUTPUT
*& Form tree_dev
text
FORM tree_dev .
DATA lv_container_name(20) TYPE c.
lv_container_name = 'ALV_TREE'.
CREATE OBJECT alv_container
EXPORTING
container_name = lv_container_name
EXCEPTIONS
cntl_error = 1
cntl_system_error = 2
create_error = 3
lifetime_error = 4
lifetime_dynpro_dynpro_link = 5
OTHERS = 6.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
CREATE OBJECT alv_tree
EXPORTING
parent = alv_container
node_selection_mode = cl_gui_column_tree=>node_sel_mode_single
item_selection = 'X'
no_toolbar = ''
no_html_header = 'X'
EXCEPTIONS
cntl_error = 1
cntl_system_error = 2
create_error = 3
lifetime_error = 4
illegal_node_selection_mode = 5
failed = 6
illegal_column_name = 7
OTHERS = 8.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
PERFORM build_hirarchy_header CHANGING gs_hirarchy_header.
PERFORM buid_fieldcatalog.
CALL METHOD alv_tree->set_table_for_first_display
EXPORTING
is_hierarchy_header = gs_hirarchy_header
CHANGING
it_outtab = gt_vbrk "Table Must be Empty
it_fieldcatalog = gt_fcat.
PERFORM create_hierarchy.
CALL METHOD alv_tree->frontend_update.
ENDFORM. " tree_dev
*& Form build_hirarchy_header
<--P_GS_HIRARCHY_HEADER text
FORM build_hirarchy_header CHANGING p_gs_hirarchy_header TYPE treev_hhdr.
p_gs_hirarchy_header-heading = 'Company Code'(001).
p_gs_hirarchy_header-tooltip = 'Comapny Code'(002).
p_gs_hirarchy_header-width = 35.
p_gs_hirarchy_header-width_pix = ''.
ENDFORM. " build_hirarchy_header
*& Form buid_fieldcatalog
FORM buid_fieldcatalog .
DATA ls_fcat TYPE lvc_s_fcat.
CALL FUNCTION 'LVC_FIELDCATALOG_MERGE'
EXPORTING
i_structure_name = 'VBRK'
CHANGING
ct_fieldcat = gt_fcat
EXCEPTIONS
inconsistent_interface = 1
program_error = 2
OTHERS = 3.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
LOOP AT gt_fcat INTO ls_fcat.
CASE ls_fcat-fieldname.
WHEN 'NETWR'.
ls_fcat-do_sum = 'X'.
ls_fcat-h_ftype = 'MAX'.
ENDCASE.
MODIFY gt_fcat FROM ls_fcat.
ENDLOOP.
ENDFORM. " buid_fieldcatalog
*& Form create_hierarchy
FORM create_hierarchy .
DATA : lt_vbrk TYPE TABLE OF vbrk,
ls_vbrk TYPE vbrk.
DATA : top_key TYPE lvc_nkey,
company_key TYPE lvc_nkey,
bzirk_key TYPE lvc_nkey.
DATA : lv_bukrs TYPE bukrs,
lv_bukrs_prv TYPE bukrs,
lv_bzirk TYPE bzirk,
lv_bzirk_prv TYPE bzirk.
SELECT * FROM vbrk INTO TABLE lt_vbrk UP TO 500 ROWS.
SORT lt_vbrk BY bukrs .
CALL METHOD alv_tree->add_node
EXPORTING
i_relat_node_key = ''
i_relationship = cl_gui_column_tree=>relat_last_child
i_node_text = 'Company Code'
IMPORTING
e_new_node_key = top_key
EXCEPTIONS
relat_node_not_found = 1
node_not_found = 2
OTHERS = 3.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
LOOP AT lt_vbrk INTO ls_vbrk.
lv_bukrs = ls_vbrk-bukrs .
lv_bzirk = ls_vbrk-bzirk .
IF lv_bukrs <> lv_bukrs_prv.
lv_bukrs_prv = lv_bukrs.
PERFORM add_node USING lv_bukrs
top_key
CHANGING company_key.
ENDIF.
IF lv_bzirk <> lv_bzirk_prv.
lv_bzirk_prv = lv_bzirk.
PERFORM add_posnr USING lv_bzirk
company_key
CHANGING bzirk_key.
ENDIF.
ENDLOOP.
ENDFORM. " create_hierarchy
*& Form add_node
-->P_LV_BUKRS text
-->P_TOP_KEY text
<--P_COMPANY_KEY text
FORM add_node USING p_lv_bukrs TYPE bukrs
p_top_key TYPE lvc_nkey
CHANGING p_company_key TYPE lvc_nkey .
DATA: l_node_text TYPE lvc_value,
ls_vbrk TYPE vbrk.
l_node_text = 'Company' .
CALL METHOD alv_tree->add_node
EXPORTING
i_relat_node_key = p_top_key
i_relationship = cl_gui_column_tree=>relat_last_child
is_outtab_line = ls_vbrk
i_node_text = l_node_text
IMPORTING
e_new_node_key = p_company_key
EXCEPTIONS
relat_node_not_found = 1
node_not_found = 2
OTHERS = 3.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
ENDFORM. " add_node
*& Form add_posnr
text
-->P_LV_POSNR text
-->P_COMPANY_KEY text
<--P_POSNR_KEY text
FORM add_posnr USING p_lv_bzirk TYPE bzirk
p_company_key TYPE lvc_nkey
CHANGING p_bzirk_key TYPE lvc_nkey.
DATA ls_vbrk TYPE vbrk.
CALL METHOD alv_tree->add_node
EXPORTING
i_relat_node_key = p_company_key
i_relationship = cl_gui_column_tree=>relat_last_child
is_outtab_line = ls_vbrk
i_node_text = 'Sales District'
IMPORTING
e_new_node_key = p_bzirk_key
EXCEPTIONS
relat_node_not_found = 1
node_not_found = 2
OTHERS = 3.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
ENDFORM. " add_posnr
*& Module USER_COMMAND_9100 INPUT
MODULE user_command_9100 INPUT.
CASE sy-ucomm.
WHEN 'BACK' OR 'EXIT' OR 'CANCEL'.
CALL METHOD alv_container->free.
LEAVE PROGRAM.
ENDCASE.
ENDMODULE. " USER_COMMAND_9100 INPUTCheck this forum there are many threads on this.
-
How to use std quality document types
Hi, Pls advise how to use std quality document types like Print list, Quality agreement, Technical delivery terms? i mean for what purpose those will be used?
hi
Quality Agreement;
Quality aggrement document type is used in Quality Info Record.If you maintain control key regarding Qaulity Aggrement you must maintain the Qaulity agg otherwise PO or GR wil be blocked.
Technical delivery:
Technical dele term are maintained in Material master-->additional data -->documents.
if you select the control key which has reference of Technical dele term you have to maintain this in MM otherwise PO or GR will be blocked.
Q01 Q-Agreement / MM-PUR
Q02 DelivTerms / MM-PUR
Both are customization in SPRO
Regards
Sujit -
Downloaded my hierarchy using the program z_sap_hierarchy_download
hi
I want download downloaded my hierarchy using the program z_sap_hierarchy_download but I have any problem when I using idoc method, I have this message:
Node [00001350, 00001580]: Leaf 'E010000000' already exists as child of node 00001501
Best regard
Francoisehi
The problem is that 2 id differents has the same description.
my program is:
begin
SAP Consulting BW Tools:
Download hierarchy into a flat file. The file has the correct format
Text elements:
P_DATES Include from/to dates
P_DATETO Valid-to date
P_FNAME File name
P_HIENM Hierarchy name
P_INTER Include from/to leaves
P_IOBJNM InfoObject
P_LANGU Language
P_VERS Hierarchy version
REPORT z_sap_hierarchy_download.
TYPE-POOLS: rs, rsdm, rrh1.
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME.
PARAMETERS:
p_iobjnm TYPE rsdiobjnm MEMORY ID rsc.
SELECTION-SCREEN END OF BLOCK b1.
SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME.
PARAMETERS:
p_hienm TYPE rshiedir-hienm,
p_vers TYPE rshiedir-version,
p_dateto TYPE rshiedir-dateto,
p_langu TYPE rshiedirt-langu.
SELECTION-SCREEN END OF BLOCK b2.
SELECTION-SCREEN BEGIN OF BLOCK b3 WITH FRAME.
PARAMETERS:
p_fname LIKE rlgrap-filename,
p_dates AS CHECKBOX DEFAULT 'X',
p_inter AS CHECKBOX DEFAULT 'X'.
SELECTION-SCREEN END OF BLOCK b3.
File structure
TYPES:
No dates/intervals
BEGIN OF y_s_hierfile_1,
nodeid TYPE rshienodid,
iobjnm TYPE rsiobjnm,
nodename TYPE rsnodename,
tlevel TYPE rstlevel,
link TYPE rslink,
parentid TYPE rsparent,
childid TYPE rschild,
nextid TYPE rsnext,
langu TYPE langu,
txtsh TYPE rstxtsh,
txtmd TYPE rstxtmd,
txtlg TYPE rstxtlg,
END OF y_s_hierfile_1,
y_t_hierfile_1 TYPE STANDARD TABLE OF y_s_hierfile_1,
With dates
BEGIN OF y_s_hierfile_2,
nodeid TYPE rshienodid,
iobjnm TYPE rsiobjnm,
nodename TYPE rsnodename,
tlevel TYPE rstlevel,
link TYPE rslink,
parentid TYPE rsparent,
childid TYPE rschild,
nextid TYPE rsnext,
dateto TYPE rsdateto,
datefrom TYPE rsdatefrom,
langu TYPE langu,
txtsh TYPE rstxtsh,
txtmd TYPE rstxtmd,
txtlg TYPE rstxtlg,
END OF y_s_hierfile_2,
y_t_hierfile_2 TYPE STANDARD TABLE OF y_s_hierfile_2,
With intervals
BEGIN OF y_s_hierfile_3,
nodeid TYPE rshienodid,
iobjnm TYPE rsiobjnm,
nodename TYPE rsnodename,
tlevel TYPE rstlevel,
link TYPE rslink,
parentid TYPE rsparent,
childid TYPE rschild,
nextid TYPE rsnext,
leafto TYPE rsleafto,
leaffrom TYPE rsleaffrom,
langu TYPE langu,
txtsh TYPE rstxtsh,
txtmd TYPE rstxtmd,
txtlg TYPE rstxtlg,
END OF y_s_hierfile_3,
y_t_hierfile_3 TYPE STANDARD TABLE OF y_s_hierfile_3,
With dates/intervals
BEGIN OF y_s_hierfile_4,
nodeid TYPE rshienodid,
iobjnm TYPE rsiobjnm,
nodename TYPE rsnodename,
tlevel TYPE rstlevel,
link TYPE rslink,
parentid TYPE rsparent,
childid TYPE rschild,
nextid TYPE rsnext,
dateto TYPE rsdateto,
datefrom TYPE rsdatefrom,
leafto TYPE rsleafto,
leaffrom TYPE rsleaffrom,
langu TYPE langu,
txtsh TYPE rstxtsh,
txtmd TYPE rstxtmd,
txtlg TYPE rstxtlg,END OF y_s_hierfile_4,
y_t_hierfile_4 TYPE STANDARD TABLE OF y_s_hierfile_4.
Hierarchy definition
DATA:
g_s_hiesel TYPE rsndi_s_hiesel,
g_s_hiedir TYPE rsndi_s_hiedir,
g_subrc TYPE sy-subrc,
g_t_hiedirt TYPE TABLE OF rshiedirt,
g_s_hierstruc TYPE rssh_s_htab,
g_t_hierstruc TYPE TABLE OF rssh_s_htab,
g_s_thiernode TYPE rsthiernode,
g_t_thiernode TYPE TABLE OF rsthiernode WITH KEY langu hieid objvers
nodename,
g_s_hierintvl TYPE rssh_s_jtab,
g_t_hierintvl TYPE TABLE OF rssh_s_jtab WITH KEY hieid objvers nodeid,
g_s_message TYPE rsndi_s_message,
g_t_message TYPE TABLE OF rsndi_s_message,
g_s_chavlinfo TYPE rsdm_s_chavlinfo,
g_t_chavlinfo TYPE rsdm_t_chavlinfo.
File
DATA:
g_fname TYPE string,
g_struct_s TYPE string,
g_struct_t TYPE string,
gr_s_file TYPE REF TO data,
gr_t_file TYPE REF TO data.
FIELD-SYMBOLS:
<g_langu> TYPE ANY,
<g_s_file> TYPE ANY,
<g_t_file> TYPE STANDARD TABLE.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_iobjnm.
CALL FUNCTION 'RSD_IOBJ_F4'
EXPORTING
i_show_cha = rs_c_true
i_objvers = rs_c_objvers-active
i_hietabfl = rs_c_true
CHANGING
c_iobjnm = p_iobjnm
EXCEPTIONS
illegal_input = 1.
CHECK sy-subrc = 0.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_hienm.
DATA:
l_s_hiertxt TYPE rrh1_s_hiertxt,
l_t_hiertxt TYPE rrh1_t_hiertxt.
CALL FUNCTION 'RRH1_HIERARCHY_HELP_VALUES_GET'
EXPORTING
i_iobjnm = p_iobjnm
i_dateto = p_dateto
i_hienm = p_hienm
i_version = p_vers
IMPORTING
e_t_hiertxt = l_t_hiertxt
EXCEPTIONS
no_f4_available = 1
dialogue_canceled = 2
OTHERS = 3.
CHECK sy-subrc = 0.
READ TABLE l_t_hiertxt INTO l_s_hiertxt INDEX 1.
CHECK NOT l_s_hiertxt IS INITIAL.
p_hienm = l_s_hiertxt-hienm.
DATA:
l_s_dynpfields TYPE dynpread,
l_t_dynpfields TYPE STANDARD TABLE OF dynpread.
CLEAR: l_t_dynpfields, l_s_dynpfields.
l_s_dynpfields-fieldname = 'P_VERS'.
WRITE l_s_hiertxt-version TO l_s_dynpfields-fieldvalue.
APPEND l_s_dynpfields TO l_t_dynpfields.
l_s_dynpfields-fieldname = 'P_DATETO'.
WRITE l_s_hiertxt-dateto TO l_s_dynpfields-fieldvalue.
APPEND l_s_dynpfields TO l_t_dynpfields.
CALL FUNCTION 'DYNP_VALUES_UPDATE'
EXPORTING
dyname = sy-repid
dynumb = sy-dynnr
TABLES
dynpfields = l_t_dynpfields.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_fname.
DATA:
l_filename1 TYPE string,
l_filename2 TYPE string,
l_path TYPE string,
l_fullpath TYPE string,
l_action TYPE i.
l_filename1 = p_fname.
CALL METHOD cl_gui_frontend_services=>file_save_dialog
EXPORTING
window_title = 'Select Download File'
default_extension = 'txt'
default_file_name = l_filename1
file_filter = 'All Files (.)|.|Text files (.txt)|.txt'
CHANGING
filename = l_filename2
path = l_path
fullpath = l_fullpath
user_action = l_action
EXCEPTIONS
cntl_error = 1
OTHERS = 2. "#EC NOTEXT
CHECK sy-subrc = 0.
CALL METHOD cl_gui_cfw=>flush.
IF l_action = 0.
p_fname = l_fullpath.
ENDIF.
INITIALIZATION.
GET PARAMETER ID 'RSC' FIELD p_iobjnm.
START-OF-SELECTION.
Check input
CHECK NOT p_fname IS INITIAL.
IF p_langu IS INITIAL.
p_langu = sy-langu.
ENDIF.
IF p_dateto IS INITIAL.
p_dateto = '99991231'.
ENDIF.
Read hierarchy
CLEAR g_s_hiesel.
g_s_hiesel-objvers = rs_c_objvers-active.
g_s_hiesel-hienm = p_hienm.
g_s_hiesel-version = p_vers.
g_s_hiesel-iobjnm = p_iobjnm.
g_s_hiesel-dateto = p_dateto.
CALL FUNCTION 'RSNDI_SHIE_STRUCTURE_GET'
EXPORTING
i_s_hiesel = g_s_hiesel
i_no_nodenm_table = rs_c_true
IMPORTING
e_s_hiedir = g_s_hiedir
e_subrc = g_subrc
TABLES
e_t_hiedirt = g_t_hiedirt
e_t_hierstruc = g_t_hierstruc
e_t_thiernode = g_t_thiernode
e_t_hierintvl = g_t_hierintvl
e_t_message = g_t_message.
IF g_subrc <> 0.
READ TABLE g_t_message INTO g_s_message INDEX 1.
IF sy-subrc = 0.
MESSAGE ID g_s_message-msgid TYPE 'I' NUMBER g_s_message-msgno
WITH g_s_message-msgv1 g_s_message-msgv2
g_s_message-msgv3 g_s_message-msgv4.
ELSE.
MESSAGE ID 'RSBO' TYPE 'I' NUMBER 899
WITH 'Hierarchy read error'.
ENDIF.
EXIT.
ENDIF.
Defined output structures
IF p_dates IS INITIAL AND p_inter IS INITIAL.
g_struct_s = 'Y_S_HIERFILE_1'.
g_struct_t = 'Y_T_HIERFILE_1'.
ELSEIF p_dates = 'X' AND p_inter IS INITIAL.
g_struct_s = 'Y_S_HIERFILE_2'.
g_struct_t = 'Y_T_HIERFILE_2'.
ELSEIF p_dates IS INITIAL AND p_inter = 'X'.
g_struct_s = 'Y_S_HIERFILE_3'.
g_struct_t = 'Y_T_HIERFILE_3'.
ELSE.
g_struct_s = 'Y_S_HIERFILE_4'.
g_struct_t = 'Y_T_HIERFILE_4'.
ENDIF.
CREATE DATA gr_s_file TYPE (g_struct_s).
ASSIGN gr_s_file->* TO <g_s_file>.
CREATE DATA gr_t_file TYPE (g_struct_t).
ASSIGN gr_t_file->* TO <g_t_file>.
Nodes
REFRESH <g_t_file>.
LOOP AT g_t_hierstruc INTO g_s_hierstruc.
CLEAR <g_s_file>.
MOVE-CORRESPONDING g_s_hierstruc TO <g_s_file>.
Texts for nodes
READ TABLE g_t_thiernode INTO g_s_thiernode WITH TABLE KEY
langu = p_langu
hieid = g_s_hierstruc-hieid
objvers = rs_c_objvers-active
nodename = g_s_hierstruc-nodename.
IF sy-subrc = 0.
MOVE-CORRESPONDING g_s_thiernode TO <g_s_file>.
ELSE.
Texts for characteristic values
REFRESH g_t_chavlinfo.
CLEAR g_s_chavlinfo.
g_s_chavlinfo-c_chavl = g_s_hierstruc-nodename.
APPEND g_s_chavlinfo TO g_t_chavlinfo.
CALL FUNCTION 'RSD_CHAVL_READ_ALL'
EXPORTING
i_iobjnm = g_s_hierstruc-iobjnm
i_langu = p_langu
i_dateto = p_dateto
i_check_value = space
i_sid_in = space
i_hieid = g_s_hiedir-hieid
i_objvers = g_s_hiedir-objvers
CHANGING
c_t_chavlinfo = g_t_chavlinfo
EXCEPTIONS
info_object_not_found = 1
routines_generation_error = 2
check_table_not_existing = 3
text_table_not_existing = 4
OTHERS = 5.
IF sy-subrc = 0.
READ TABLE g_t_chavlinfo INTO g_s_chavlinfo INDEX 1.
IF sy-subrc = 0.
MOVE-CORRESPONDING g_s_chavlinfo-e_chatexts TO <g_s_file>.
ASSIGN COMPONENT 'LANGU' OF STRUCTURE <g_s_file> TO <g_langu>.
IF sy-subrc = 0.
<g_langu> = p_langu.
ENDIF.
ENDIF.
ENDIF.
ENDIF.
Intervals
IF g_s_hierstruc-intervl = 'X' AND p_inter = 'X'.
READ TABLE g_t_hierintvl INTO g_s_hierintvl WITH TABLE KEY
hieid = g_s_hierstruc-hieid
objvers = rs_c_objvers-active
nodeid = g_s_hierstruc-nodeid.
IF sy-subrc = 0.
MOVE-CORRESPONDING g_s_hierintvl TO <g_s_file>.
ENDIF.
ENDIF.
APPEND <g_s_file> TO <g_t_file>.
ENDLOOP.
Download output table
g_fname = p_fname.
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
filename = g_fname
write_field_separator = space
TABLES
data_tab = <g_t_file>
EXCEPTIONS
file_write_error = 1
no_batch = 2
gui_refuse_filetransfer = 3
invalid_type = 4
no_authority = 5
unknown_error = 6
header_not_allowed = 7
separator_not_allowed = 8
filesize_not_allowed = 9
header_too_long = 10
dp_error_create = 11
dp_error_send = 12
dp_error_write = 13
unknown_dp_error = 14
access_denied = 15
dp_out_of_memory = 16
disk_full = 17
dp_timeout = 18
file_not_found = 19
dataprovider_exception = 20
control_flush_error = 21
OTHERS = 22.
IF sy-subrc = 0.
MESSAGE ID 'RSBO' TYPE 'I' NUMBER 899
WITH 'Hierarchy download successful!'.
ELSE.
MESSAGE ID sy-msgid TYPE 'I' NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
end -
Hi,
We would like to build customer Hierarchy using MDM that would match the DUNS hierarchy. Is this possible to Model this using MDM?
Thanks,
SanjayHi Sanjay,
I never tried to analyze the DUNS hierarchy. But, hope you know that MDM supports different table types and Hierarchy table is one among them.
Regards,
Rajani Kumar -
Error while reading equipment hierarchy using FM EQUI_HIERARCHY_READ
Hi,
I have a requirement to change the plant, asset master profit center and purchase order data for an equipment, for this I have written a module pool program which has selection and main subscreens where selection screen displays the selection criteria and main screen displays the output with the plant as editable field.
The program has two buttons, one is to display the equipment details based on the equipment data provided in the selection screen and another one is to update the master tables with the changed value.
The issue is after editing the plant and updating the equipment master tables, if I again try to display the equipment in the same session by clicking on the display button, it is displaying the old value instead of the new one (updated plant value). Irrespective of the number of times u change the value it is still showing the initial value only instead of the latest one even though I refreshed the output table which is displayed in the ALV container as well the ALV container before displaying the data in it.
I'm reading the equipment hierarchy data using the function module "EQUI_HIERARCHY_READ" where it is returning the old value instead of the updated values. I am calling this function module in a method of my own class. Its happening only when I call it in the class, but If I run the same function module in a report of same logic, it is returning the updated values.
Pls. advise me how can I get the updated value.
Edited by: sailaja reddy on Jan 19, 2011 3:29 PM
Edited by: sailaja reddy on Jan 19, 2011 3:29 PMThank you Jay,
I have tried with both the options, still I am getting the old values. This program is to modify plant and profit center in both equipment master as well PO. Once after updating the plant and profit center I am able to display PO plant and profit center with updated values but not the equipment related plant and profit center If I run it in the same session. -
How can i create Level Based Hierarchy using multiple logical table.
Hi All,
in my use case i have two master logical table.
Division_Mst(divncd,DivnName)
Department_Mst(deptcd,DeptName)
and one logical table which contain both column Header (divncd,deptcd)
and fact table detail where one measure column(empcd) using aggregation count on it.
so i want to create levelbased hierarchy like this.
DivnName
|------DeptName
which are come from(Division_Mst,Department_Mst) .
so user can see no of employees division wise and drill down to Department wise.
How can i achieved this?
thanks
ManishCheck out Shay's blog https://blogs.oracle.com/shay/entry/adf_faces_dynamic_tags_-fora
Timo -
Except function with parent child hierarchy using mdx query
HI,
I need to remove some items using mdx query in parent child hierarchy.
I tried with below query,it is not removeing ,could you please help me.
SELECT
{[Measures].[Amount]} ON
COLUMNS
NonEmpty([Account].[Accounts].[Account Level 01],[Measures].[Amount])
ON ROWS
FROM (SELECT
-Descendants({[Account].[Accounts].&[47]},,Leaves)
} ON COLUMNS
FROM [Adventure Works])
induHi Indu,
Why do you remove some itmes using
Descendants function? Generally, we use FILTER function to achieve the requirement.
WITH SET [CustomAccounts] AS
FILTER ([Account].[Accounts].[Account Level 01].Members , [Account].[Accounts].CurrentMember.Name<>'Net Income')
SELECT {[Measures].[Internet Sales Amount]} ON 0
[CustomAccounts] ON 1
FROM [Adventure Works]
WITH SET [CustomAccounts] AS
FILTER ([Account].[Accounts].[Account Level 01].Members , [Account].[Accounts].CurrentMember.Name='Net Income')
SET [RemainingAccount] AS
[Account].[Accounts].[Account Level 01]- [CustomAccounts]
SELECT {[Measures].[Reseller Sales Amount]} ON 0
[RemainingAccount] ON 1
FROM [Adventure Works]
Results.
References.
http://www.databasejournal.com/features/mssql/article.php/3306101/MDX-Essentials-Basic-Set-Functions-The-Filter-Function.htm
http://social.msdn.microsoft.com/Forums/sqlserver/en-US/c0149678-97f2-4066-903f-7f9e9ff09b56/filtering-out-dimension-members-with-mdx?forum=sqlanalysisservices
Regards,
Charlie Liao
If you have any feedback on our support,
please click here.
Charlie Liao
TechNet Community Support -
Multiple Hierarchy Use in EVDRE
Hi,
How to use the PARENTH2 hierarchy in Evdre report.
I need that always the report opens with H2 hierarchy instead of using H1. Tried using MEMBERS(H2) but does not work.
Please advice...
Regards,
AbhinavHi Abhinav,
Try to use ALL instead. That is, ALL(H2) which was working as the MDX key word in MS.
Regards,
YH Seo
=============================================================================================
Hi,
How to use the PARENTH2 hierarchy in Evdre report.
I need that always the report opens with H2 hierarchy instead of using H1. Tried using MEMBERS(H2) but does not work.
Please advice...
Regards,
Abhinav
Maybe you are looking for
-
I am trying to install Adobe Photoshop CS4 for the first time (it's not an upgrade) from the trying versión of adobe.com on Mac OS X 10.6 (all the latest updates are installed). The Mac install is also pretty fresh, although I have installed a few th
-
mysystem : pent IV , 2400 mhz ,52 MB ram -- usb2 - ADSL internet !!my question : i chat with skype and the " old " creative ( 460x260 ) minimum the last year -- WITHOUT ONE PROBLEM ---- YESTERDAY i take the NEW ONE from the shop and install ( 800x600
-
Adobe Acrobat 9 Pro V9.4.0 Win7 Pro x64 Problem: In Initial View, can you set defaults for Navigation tab, Page layout, and Magnification? Every time Acrobat scans a document, I have to go to Initial View to set Navigation tab, Page layout, and Magni
-
PSU level of RMAN Catalog DB version and Target DBs
Catalog DB Version: 11.2.0.2.3 Target DBs : 11.2.0.2.3 Currently our Catalog DB and Target DBs ( 15 of them) are of the same PSU level. We are going to apply PSU 5 (11.2.0.2.3) on some of the target DBs . Should we apply PSU 5 (11.2.0.2.3) on the Cat
-
How to put my name on photo?
Hi everyone, Can someone please advise on how to put your name on a Photo to deter people from coping your photograph? I have i Photo 09. If you need more information let me know as I don't know what else to put? Thanks.