Wrong data to PPA_TRANSCONTROL and would like to remove it,
search cancel

Wrong data to PPA_TRANSCONTROL and would like to remove it,

book

Article ID: 186212

calendar_today

Updated On:

Products

Clarity PPM SaaS

Issue/Introduction

Wrong data was posted to PPA_TRANSCONTROL, how to correct this

Environment

Release : All Supported Clarity releases

Resolution

Make sure the data in PPA_TRANSCONTROL and PPA_TRANSCONTROL_VALUES are only the ones to remove

Backup PPA_TRANSCONTROL and PPA_TRANSCONTROL_VALUES tables
Run the Sql query statements 

For Example:

If you want to remove records for certain dates you will need to run queries that are based on the date.

Since the TRANSDATE is only in PPA_TRANSCONTROL we recommend deleting from PPA_TRANSCONTROL_VALUES first using query similar to

1. Back up PPA_TRANSCONTROL and PPA_TRANSCONTROL_VALUES

2.  run the select queries to make sure you get the correct data

a)     select *  from ppa_transcontrol where transdate > = <enter the date for entries you want to removed>

b)    select * from ppa_transcontrol_values where transno in
       (select transno from ppa_wip where transdate > = <enter the date for entries you want to removed>  
  
     - this should be 5x the rows found in ppa_transcontrol as it holds 5 different currency types.

3.  Run the delete queries.  Delete from ppa_transcontrol_values first

     delete from ppa_transcontrol_values where transno in
     (select transno from ppa_wip where transdate > = <enter the date for entries you want to removed>

Then basically the same query for ppa_transcontrol

    delete from ppa_transcontrol where transdate > = <enter the date for entries you want to removed>