Project and Portfolio Management Practitioners Forum
cancel

Clearing Table Componenet Entries

Highlighted
Shankar Bhoi
Regular Contributor.

Clearing Table Componenet Entries

In HP PPM 7.5, is there any way we can delete the table componenet entries in the workflow. Basically if a new request is created by copying from an existing one, then whatever table componenet entires were there in the old request is not relevent in the new request and need to be deleted.
12 REPLIES
Shankar Bhoi
Regular Contributor.

Re: Clearing Table Componenet Entries

Note - We dont want to use any stored procedure.
Nisha Kurien
Honored Contributor.

Re: Clearing Table Componenet Entries

You can use a rule to clear the contents of the table component on Creation of the request.
This would be the simplest and most straightforward approach without needing to write any SQL code.

- Nisha Kurien
Sangiliraja_1
Honored Contributor.

Re: Clearing Table Componenet Entries

Hi Nisha,

I think we wont be able to have a table component as a dependency in rule.

Am i right? If you have the answer for Shankar's question with rule, please show us.

Thanks
Sangiliraja.P
Shankar Bhoi
Regular Contributor.

Re: Clearing Table Componenet Entries

yes..it will be good if we can do it with rules...I just tried with commands/temporary scripts in the workflow execution step . It seems to work. PLease let me know you see any issues..

-----
ksc_set HANDLE="[REQ.REQUEST_ID]_[SYS.UNIQUE_IDENTIFIER]"
ksc_comment --- Build a temporary script to delete table entries ----
ksc_begin_script "[AS.PKG_TRANSFER_PATH]../[HANDLE].sql"
delete from kcrt_table_entries
where request_id = [REQ.REQUEST_ID];
commit;
exit
ksc_end_script
ksc_comment --- Execute the script----
ksc_local_exec chmod 777 "[AS.PKG_TRANSFER_PATH]../[HANDLE].sql"
ksc_local_exec [AS.ORACLE_HOME]/bin/[AS.SQLPLUS] [AS.DB_USERNAME]/[AS.DB_PASSWORD]@[AS.DB_CONNECTION_STRING] @[AS.PKG_TRANSFER_PATH]../[HANDLE].sql
ksc_local_exec rm [AS.PKG_TRANSFER_PATH]../[HANDLE].sql
-------
Milind Kapdoska
Regular Contributor.

Re: Clearing Table Componenet Entries

Try this one.

Method 1
On "not submitted" status dependency to clear the table component.

This does not work
Method 2
Put a dummy execution step as first step in the workflow. Set a dummy status on this step. On this status mark the status dependency for the table component to clear out.
Nisha Kurien
Honored Contributor.

Re: Clearing Table Componenet Entries

Sangiliraja.P - In 7.5 I'm able to use/call the table component field in a rule. However, I haven't gotten a chance to test if the columns/data within the table component would clear.

- Nisha Kurien
Shankar Bhoi
Regular Contributor.

Re: Clearing Table Componenet Entries

Milind.

I dont see any details for the 2 methods you ahve mentioned. Is there any attchements.
Sangiliraja_1
Honored Contributor.

Re: Clearing Table Componenet Entries

Hi Nisha,

I am also in PPM 7.5 SP 4.

Please confirm are u able to see table component in Rules dependecies section.

Thanks
Sangiliraja.p
Sangiliraja_1
Honored Contributor.

Re: Clearing Table Componenet Entries

Hi Nisha,

Sorry there is no use of havin table component in Dependencies section.

Are u able to see it in Results Section.

Thanks
Sangiliraja.P
Nisha Kurien
Honored Contributor.

Re: Clearing Table Componenet Entries

Hi Sangiliraja,

Yes, you are correct. I'm not able to see it in the Result Fields. This rules the option out completely.

Thanks
Nisha
Sangiliraja_1
Honored Contributor.

Re: Clearing Table Componenet Entries

Hi Shankar,

Now i think you are left with option of using a function called from a execution step performing the function for you. This execution step should be the 1st one in your workflow.

Thanks
Sangiliraja.P
Shankar Bhoi
Regular Contributor.

Re: Clearing Table Componenet Entries

Thanks.