How to find first level WBS from Lower Level WBS
My client is posting cost at wbs which will be at level 5 or 6 and i need to find 1st level wbs for that 5 or 6 level wbs..
So Is there any Function module to find 1st level wbs from any lower levels...
or any suitable code?
Hi Sachin,
in table PRHI you have the relationship between a WBS element and its superior level WBS element.
For example:
Level 1: XYZ (internal code PSPNR: 00000001)
..Level 2: ABC (internal code PSPNR: 00000002)
..Level 2: DEF (internal code PSPNR: 00000003)
....Level 3: PQR (internal code PSPNR: 00000004)
...then in table PRHI you'll have:
PRHI-POSNR = 00000001 ... PRHI-UP = 00000000
PRHI-POSNR = 00000002 ... PRHI-UP = 00000001
PRHI-POSNR = 00000003 ... PRHI-UP = 00000001
PRHI-POSNR = 00000004 ... PRHI-UP = 00000002
...meaning:
WBS element XYZ is top level
WBS element ABC depends of WBS element XYZ
WBS element DEF depends of WBS element XYZ
WBS element PQR depends of WBS element DEF
Then you can iteratively (or recursively) "climb up" the structure of the project until the WBS element of level 1.
I hope this helps. Best regards,
Alvaro
Similar Messages
-
How to get first level BOM material if I know 4th level material code only?
Dear all,
I have 4th level BOM material only. How to find first level ( finish material) BOM material ?
We can find bottom level material easily through CS11 if we know top level material.
But how to find top material if we don't know ? we know only bottom most material.........
Thanks....Kishore,
Multiple runs of "CS15" will help you.
Regards,
Prasobh -
How to find the level of each child table in a relational model?
Earthlings,
I need your help and I know that, 'yes, we can change'. Change this thread to a answered question.
So: How to find the level of each child table in a relational model?
I have a relacional database (9.2), all right?!
O /* This is a child who makes N references to each of the follow N parent tables (here: three), and so on. */
/↑\ Fks
O"O O" <-- level 2 for first table (circle)
/↑\ Fks
"o"o"o" <-- level 1 for middle table (circle)
↑ Fk
"º"Tips:
- each circle represents a table;
- red tables no have foreign key
- the table in first line of tree, for example, has level 3, but when 3 becomes N? How much is N? This's the question.
I started thinking about the following:
First I have to know how to take the children:
select distinct child.table_name child
from all_cons_columns father
join all_cons_columns child
using (owner, position)
join (select child.owner,
child.constraint_name fk,
child.table_name child,
child.r_constraint_name pk,
father.table_name father
from all_constraints father, all_constraints child
where child.r_owner = father.owner
and child.r_constraint_name = father.constraint_name
and father.constraint_type in ('P', 'U')
and child.constraint_type = 'R'
and child.owner = 'OWNER') aux
using (owner)
where child.constraint_name = aux.fk
and child.table_name = aux.child
and father.constraint_name = aux.pk
and father.table_name = aux.father;Thinking...
Let's Share!
My thanks in advance,
Philips
Edited by: BluShadow on 01-Apr-2011 15:08
formatted the code and the hierarchy for readbilityJustin,
Understood.
Nocycle not work in 9.2 and, even that would work, would not be appropriate.
With your help, I decided a much simpler way (but there is still a small problem, <font color=red>IN RED</font>):
-- 1
declare
type udt_roles is table of varchar2(30) index by pls_integer;
cRoles udt_roles;
begin
execute immediate 'create user philips
identified by philips';
select granted_role bulk collect
into cRoles
from user_role_privs
where username = user;
for i in cRoles.first .. cRoles.count loop
execute immediate 'grant ' || cRoles(i) || ' to philips';
end loop;
end;
-- 2
create table philips.root1(root1_id number,
constraint root1_id_pk primary key(root1_id)
enable);
grant all on philips.root1 to philips;
create or replace trigger philips.tgr_root1
before delete or insert or update on philips.root1
begin
null;
end;
create table philips.root2(root2_id number,
constraint root2_id_pk primary key(root2_id)
enable);
grant all on philips.root2 to philips;
create or replace trigger philips.tgr_root2
before delete or insert or update on philips.root2
begin
null;
end;
create table philips.node1(node1_id number,
root1_id number,
node2_id number,
node4_id number,
constraint node1_id_pk primary key(node1_id)
enable,
constraint n1_r1_id_fk foreign key(root1_id)
references philips.root1(root1_id) enable,
constraint n1_n2_id_fk foreign key(node2_id)
references philips.node2(node2_id) enable,
constraint n1_n4_id_fk foreign key(node4_id)
references philips.node4(node4_id) enable);
grant all on philips.node1 to philips;
create or replace trigger philips.tgr_node1
before delete or insert or update on philips.node1
begin
null;
end;
create table philips.node2(node2_id number,
root1_id number,
node3_id number,
constraint node2_id_pk primary key(node2_id)
enable,
constraint n2_r1_id_fk foreign key(root1_id)
references philips.root1(root1_id) enable,
constraint n2_n3_id_fk foreign key(node3_id)
references philips.node3(node3_id) enable);
grant all on philips.node2 to philips;
create or replace trigger philips.tgr_node2
before delete or insert or update on philips.node2
begin
null;
end;
create table philips.node3(node3_id number,
root2_id number,
constraint node3_id_pk primary key(node3_id)
enable,
constraint n3_r2_id_fk foreign key(root2_id)
references philips.root2(root2_id) enable);
grant all on philips.node3 to philips;
create or replace trigger philips.tgr_node3
before delete or insert or update on philips.node3
begin
null;
end;
create table philips.node4(node4_id number,
node2_id number,
constraint node4_id_pk primary key(node4_id)
enable,
constraint n4_n2_id_fk foreign key(node2_id)
references philips.node2(node2_id) enable);
grant all on philips.node4 to philips;
create or replace trigger philips.tgr_node4
before delete or insert or update on philips.node4
begin
null;
end;
-- out of the relational model
create table philips.node5(node5_id number,
constraint node5_id_pk primary key(node5_id)
enable);
grant all on philips.node5 to philips;
create or replace trigger philips.tgr_node5
before delete or insert or update on philips.node5
begin
null;
end;
-- 3
create table philips.dictionary(table_name varchar2(30));
insert into philips.dictionary values ('ROOT1');
insert into philips.dictionary values ('ROOT2');
insert into philips.dictionary values ('NODE1');
insert into philips.dictionary values ('NODE2');
insert into philips.dictionary values ('NODE3');
insert into philips.dictionary values ('NODE4');
insert into philips.dictionary values ('NODE5');
--4
create or replace package body philips.pck_restore_philips as
procedure sp_select_tables is
aExportTablesPhilips utl_file.file_type := null; -- file to write DDL of tables
aExportReferencesPhilips utl_file.file_type := null; -- file to write DDL of references
aExportIndexesPhilips utl_file.file_type := null; -- file to write DDL of indexes
aExportGrantsPhilips utl_file.file_type := null; -- file to write DDL of grants
aExportTriggersPhilips utl_file.file_type := null; -- file to write DDL of triggers
sDirectory varchar2(100) := '/app/oracle/admin/tace/utlfile'; -- directory \\bmduhom01or02
cTables udt_tables; -- collection to store table names for the relational depth
begin
-- omits all referential constraints:
dbms_metadata.set_transform_param(dbms_metadata.session_transform, 'REF_CONSTRAINTS', false);
-- omits segment attributes (physical attributes, storage attributes, tablespace, logging):
dbms_metadata.set_transform_param(dbms_metadata.session_transform, 'SEGMENT_ATTRIBUTES', false);
-- append a SQL terminator (; or /) to each DDL statement:
dbms_metadata.set_transform_param(dbms_metadata.session_transform, 'SQLTERMINATOR', true);
-- create/open files for export DDL:
aExportTablesPhilips := utl_file.fopen(sDirectory, 'DDLTablesPhilips.pdc', 'w', 32767);
aExportReferencesPhilips := utl_file.fopen(sDirectory, 'DDLReferencesPhilips.pdc', 'w', 32767);
aExportIndexesPhilips := utl_file.fopen(sDirectory, 'DDLIndexesPhilips.pdc', 'w', 32767);
aExportGrantsPhilips := utl_file.fopen(sDirectory, 'DDLGrantsPhilips.pdc', 'w', 32767);
aExportTriggersPhilips := utl_file.fopen(sDirectory, 'DDLTriggersPhilips.pdc', 'w', 32767);
select d.table_name bulk collect
into cTables -- collection with the names of tables in the schema philips
from all_tables t, philips.dictionary d
where owner = 'PHILIPS'
and t.table_name = d.table_name;
-- execution
sp_seeks_ddl(aExportTablesPhilips,
aExportReferencesPhilips,
aExportIndexesPhilips,
aExportGrantsPhilips,
aExportTriggersPhilips,
cTables);
-- closes all files
utl_file.fclose_all;
end sp_select_tables;
procedure sp_seeks_ddl(aExportTablesPhilips in utl_file.file_type,
aExportReferencesPhilips in utl_file.file_type,
aExportIndexesPhilips in utl_file.file_type,
aExportGrantsPhilips in utl_file.file_type,
aExportTriggersPhilips in utl_file.file_type,
cTables in out nocopy udt_tables) is
cDDL clob := null; -- colletion to save DDL
plIndex pls_integer := null;
sTableName varchar(30) := null;
begin
for i in cTables.first .. cTables.count loop
plIndex := i;
sTableName := cTables(plIndex);
* Retrieves the DDL and the dependent DDL into cDDL clob *
* for the selected table in the collection, and writes to file.*
begin
cDDL := dbms_metadata.get_ddl('TABLE', sTableName, 'PHILIPS');
sp_writes_ddl(aExportTablesPHILIPS, cDDL);
exception
when dbms_metadata.object_not_found then
null;
end;
begin
cDDL := dbms_metadata.get_dependent_ddl('REF_CONSTRAINT', sTableName, 'PHILIPS');
sp_writes_ddl(aExportReferencesPhilips, cDDL);
exception
when dbms_metadata.object_not_found2 then
null;
end;
begin
cDDL := dbms_metadata.get_dependent_ddl('INDEX', sTableName, 'PHILIPS');
sp_writes_ddl(aExportIndexesPhilips, cDDL);
exception
when dbms_metadata.object_not_found2 then
null;
end;
begin
cDDL := dbms_metadata.get_dependent_ddl('OBJECT_GRANT', sTableName, 'PHILIPS');
sp_writes_ddl(aExportGrantsPhilips, cDDL);
exception
when dbms_metadata.object_not_found2 then
null;
end;
begin
cDDL := dbms_metadata.get_dependent_ddl('TRIGGER', sTableName, 'PHILIPS');
sp_writes_ddl(aExportTriggersPhilips, cDDL);
exception
when dbms_metadata.object_not_found2 then
null;
end;
end loop;
end sp_seeks_ddl;
procedure sp_writes_ddl(aExport in utl_file.file_type,
cDDL in out nocopy clob) is
pLengthDDL pls_integer := length(cDDL);
plQuotient pls_integer := null;
plRemainder pls_integer := null;
begin
* Register variables to control the amount of lines needed *
* for each DDL and the remaining characters to the last row. *
select trunc(pLengthDDL / 32766), mod(pLengthDDL, 32766)
into plQuotient, plRemainder
from dual;
* Join DDL in the export file. *
* ps. 32766 characters + 1 character for each line break. *
-- if the size of the DDL is greater than or equal to limit the line ...
if plQuotient >= 1 then
-- loops for substring (lines of 32766 characters + 1 break character):
for i in 1 .. plQuotient loop
utl_file.put_line(aExport, substr(cDDL, 1, 32766));
-- removes the last line, of clob, recorded in the buffer:
cDDL := substr(cDDL, 32767, length(cDDL) - 32766);
end loop;
end if;
* If any remains or the number of characters is less than the threshold (quotient = 0), *
* no need to substring. *
if plRemainder > 0 then
utl_file.put_line(aExport, cDDL);
end if;
-- record DDL buffered in the export file:
utl_file.fflush(aExport);
end sp_writes_ddl;
begin
-- executes main procedure:
sp_select_tables;
end pck_restore_philips;<font color="red">The problem is that I still have ...
When creating the primary key index is created and this is repeated in the file indexes.
How to avoid?</font> -
How to find High level water mark
Hi all,
How to find high level water mark of a table.
Thanks,
Bhanu Chander.Probably you mean High Water Mark.
select blocks from user_segments where segment_name='YOUR TABLE';
exec dbms_stats.gather_table_stats('YOU','YOUR TABLE')
select blocks from user_tables where table_name='YOUR TABLE';
subtract the last number from the first number. That is where your High Water Mark stands.
Kind regards
Uwe
http://uhesse.wordpress.com
Correction: The last number is where your HWM stands. The difference between the two numbers is the amount of blocks where no row has been yet :-)
Edited by: Uwe Hesse on 26.06.2009 21:00 -
How to find the CPU utilization from the portal front end
HI Guys,
I want to find the CPU utilization from the portal front end browser screen.Can you please let me know how to find this and also the path to find it.
And how to find the CPU utilization from the server.What is the command to find the CPU utilization at unix level.
Regards,
Krishnam.hi you can create transient field in view object indicate to visibility of row (boolean ) and create view criteria that show only rows that are able to be visible according to transient attribute and at the update process set the attribute to true inside entityImpl class
-
Discoverer Report: How to find Business Area name from Report Name.
Hi
I opened a report in Disco Desktop 4 -> Resonsibiolity --> Report Name.
So I know Report name but don’t know which Business Area it belongs to.
How to find Business Area Name from Report Name?
Cheers
VijayHi,
There is no relationship between reports and business areas. Each report can be built from many folders. Each folder can be in many business areas.
However you can try the following SQL which may give you the result you want for an v5 EUL. You will have to modify for Discoverer 4 EUL:
select distinct doc_name, obj.obj_name folder_name, bas.ba_name
from eul_us.eul5_documents doc
, eul_us.eul5_elem_xrefs xref
, eul_us.eul5_expressions exp
, eul_us.eul5_objs obj
, eul_us.eul5_ba_obj_links bol
, eul_us.eul5_bas bas
where xref.ex_from_id = doc.doc_id
and doc.doc_name = &your_report
and xref.ex_to_id = exp.exp_id
and obj.obj_id = exp.it_obj_id
and bol.bol_obj_id = obj.obj_id
and bas.ba_id = bol.bol_ba_id
Rod West -
HOW TO FIND OUT TABLE DESCRIPTION FROM JDBC?
HOW WILL FIND OUT TABLE DESCRIPTION FROM JDBC?
Have a look at ResultSetMetaData
getColumnCount()
getColumnName(int)
getColumnTypeName(int)
getColumnDisplaySize(int)
***Annie*** -
How to find out company code from a plant ?
Hello friends,
I have to modify a program that uses FM "BAPI_COMPANYCODE_GET_PERIOD". For that, we have to export company code ID. Currently it is hard coded with one company code. Now we want to make this program usable by all company codes. So instead of hard coding, I would like to dynamically find out company code based on the plant. So I want to know - how to find out company code from a plant ? Is there any table that has plant to company-code assignment data, or any other FM/BAPI to get this info ?
Thanks,
- Chetanhi
u can find this from table T001K
or just goto EC01
here click on STRUCTURE>NAVIGATION
double click on co code u will get the list
u can slo try this in EC02
regards
kunal -
How to find the data loaded from r/3 to bw
hi
how to find the data loaded from r/3 to bw is correct . i am not able to find which feild in the query is connected to which feild in the r/3 . where i am geting the data from r/3 . is there any process to find which feild and table the data is comming from . plz help
thanks in advance to u allHi Veda ... the mapping between R/3 fields and BW InfoObjects should take place in Transfer Rules. Other transformation could take place in Update Rule.
So you could proceed this way: look at InfoProvider Data Model and see if the Query does perform any calculation (even with Virtual keyfigures / chars). Than go back to Update Rules and search for other calculation / transformation. At least there are Tranfer Rule and eventually DataSource / Extraction Enhancements.
As you can easily get there are many points where you have to look for ... it's a quite complex work but very usefull.
Once you will have identified all mappings / transfromation see if BW data matchs R/3 (considering calculations ...)
Good job
GFV -
How to find the form name from VA02 T.code
how to find the form name from VA02 T.code
Hi Rajyam,
I guess you are looking out for the formname which prints sales related documents.
If this is what you want,then go to the T-code NACE and select the option K1Sales activities and click on the Output Types button on the top.The new window has all the types of Output types listed.Select the most appropriate and double click on the Processing routines button in the left side screen.
The new window lists the program names and the forms associated with that output type.
In case you have any further clarifications,do let me know.
Regards,
Puneet Jhari. -
May i ask how to find the history website from safari in the new Mavericks?
may i ask how to find the history website from safari in the new Mavericks?
Choose Show All History from the History menu.
(93509) -
How to find the dsn name from an *.rpd file provided?
How to find the dsn name from an *.rpd file provided? All the ODBC details which would require to run your dashboard.
Hi
DSN name is not a part of .rpd file. So There is no information about DSN name in .rpd file.
Thanks
Siddhartha P -
How to find the message_ID/Reference_ID from a IDOC number
hi
can some one tell me how to find the message_ID/Reference_ID from a IDOC number
regards
Buddhikehi,
check the t.code IDX5 .
also check the below link for reference
Monitoring the IDOC Adapter in XI/PI using IDX5
Monitoring the IDOC Adapter in XI/PI using IDX5
regards
kummari
Edited by: kummari on Jul 28, 2008 9:20 AM -
How to find Outbound Idoc number from inbound Idoc number.
Hi,
I have one inbound Idoc in my system, then
How to find the idoc number from the system which sends that idoc(Outbound Idoc number).Hello
You can use fm SREL_GET_NEXT_NEIGHBORS for this purpose.
Scenario: An EDI purchase order is received by SAP-XI and forwarded as Inbound ORDERS IDoc to R/3. SAP-XI generates an (outbound) IDoc number which differs from the (inbound) ORDERS05 IDoc in the R/3 system.
Calling fm SREL_GET_NEXT_NEIGHBORS with the following parameters:
OBJECT-OBJKEY = <IDoc number, 16-digits>
OBJECT-OBJTYPE = 'IDOC'
MAX_HOPS = '99' " <<< get all links
I get the following result:
0000000000133906 IDOC CUSTOMER OUTIDOC
0000000000407402 IDOC INIDOC
000000370383 BUS2012 CUSTOMER OUTBELEG
0010057944 BUS2032 INBELEG
Outbound IDoc number
Inbound IDoc number (ORDERS05)
PO number
Sales order (created from inbound ORDERS IDoc)
Regards
Uwe -
How to find the group ids from which the mail has been sent
Hi,
We are able to see the list of mails have been sent to respective mail ids with the help of tcode SOST.
Is there any way to find through which group ids the mails have been sent.
Tehe details showing as the mail has been sent by Batchusr.
Please suggest how to find the group id from where the the mails have been triggered.
Regards,
Jena.Hi
This is not helpfull
If you open any notification QM03, there you will get tab " Action Log"
If you click on action log , there are two fileds
Date and time for task release
I want to fetch these fileds in one of Z report.
I am unable to find table name for these two fileds
Task release Date
Task release Time
Can we add 'QN CHANGE DATE' parameter in the selection screen (just like QN creation date) w/ range? The user want to run the report by QN change date as well.
Maybe you are looking for
-
Media Encoder CC not listed in the list of app in CC
I'm running Windows 7 Ultimate and I am a Adobe Creative Cloud for Teams member. I'm trying to install the new version of Media Encoder, but when i open Creative Cloud app it is not listed in the long list of apps. I have CS6 and CC installed on my
-
BW / SolMan Logical System Change
Hello all, I am having a BW related issue and would really appreciate some advice. I realize some of this is for the solMan forums and will cross post (I normally dont) ENVIRONMENT New installation of Solution Manager EhP1 (19). System name is ED0.
-
JTable -showing column headers and displaying multi-line strings
Hi, This is two questions really. #1 - Does anyone know why my column headers aren't showing in my jtable using the model below? #2 - Does anyone know how I can display, mulitple line strings in a jtable? Currently my newline character ('\n') is just
-
Can't open any videos from the web
Hi! I can't open youtube, IMDB or dailymoyion in my MacBook Air, all of a sudden. I am using MAC OSX v. 10.6.8. Can anyone help me? I tried every answer available on the internet...
-
Laptop doesnt boot into Windows
My daughter put my Laptop( Pavilion 14, 4 months old) down from the bed. Now the laptop doesnt start at all. It shows up an error message during boot Hard Disk 1 (3F1). I have important data to be fetched so I'm worried. Any idea how to tackle this i