‎2005 May 27 5:16 PM
Hi to all,
I am using BAPI_PROJECT_MAINTAIN to add WBS elements to an EXISTING project for example at level-2.
The project stucture is as below:
====================
WBS1 Level-1
WBS2 Level-2
WBS3 Level-2
WBS4 Level-3
WBS5 Level-1
WBS6 Level-1
====================
I wanto to add new WBS at level 2 to this exsisting project with the up structure, so that I can obtain the structure below
====================
WBS1 Level-1
WBS2 Level-2
WBS3 Level-2
WBS3a Level-2
WBS4 Level-3
WBS5 Level-1
WBS6 Level-1
====================
How can I do? Using BAPI_PROJECT_MAINTAIN I have an error.
I have problems with hierarchy?
Thank you very much,
Antonio
‎2005 May 27 11:12 PM
Hi,
Try to activate error log for BAPI_PROJECT_MAINTAIN using:
METHOD_PROJECT-OBJECTTYPE = 'Trace'.
METHOD_PROJECT-METHOD = 'Create'.
METHOD_PROJECT-OBJECTKEY = FILENAME.
APPEND METHOD_PROJECT.
I think that the best approach is first to read hierarchy using:
CALL FUNCTION 'BAPI_PROJECT_GETINFO'
EXPORTING
PROJECT_DEFINITION = PROJECT_DEFINITION-PROJECT_DEFINITION
IMPORTING
RETURN = RETURN
TABLES
E_WBS_HIERARCHIE_TABLE = WBS_HIERARCHIE_TABLE.
and then modify it accordingly
Krzys
‎2005 Jul 07 3:44 PM
Hello Antonio!
I don't know if you already solved the problem, I had to do the same thing,
First you need to create the element (you can use the BAPI with method CREATE), and then you need to rebuild the hierarchy (with the same bapi with other paramethers), for the second step I used BAPI_PROJECT_GETINFO which Krzys suggested, with that you can get the actual hierarchy and then modify it as you need,
The documentation in BAPI transaction is very helpful with the paramethers you need to use,
I hope it helps,
Frinee
‎2005 Aug 05 2:49 PM
Hi,
Based on the above notes and lots of test, we are not able to update the Project hieararchy. I created the Project and WBS using the BAPI successfully, but all the WBS are level 1. I am unable to restructure the WBS to other lower levels. Any input will be appreciated.
thanks
-satish
‎2011 Jun 08 4:09 PM
Hi All and Satish,
I am having trouble updating Hierarchy using BAPI_PROJECT_MAINTAIN function module. Any solution or code please?
Thanks
ABAPer