Solved

Oracle ADF PS_TXN Table is safe to truncate or delete?

Posted on 2014-11-07
5
2,354 Views
Last Modified: 2014-11-12
Good day, i've been finding some strange stuff  while diving into Oracle ADF framework.
I would like to know what could happen if i delete every old record in the table PS_TXN when using Oracle ADF.
Also, what is the main purpose of this table?
This is configured in the AppModule of the application.
Thanks in advance.
0
Comment
Question by:JavierVera
  • 2
  • 2
5 Comments
 
LVL 1

Author Comment

by:JavierVera
ID: 40431952
hi, please now that you are part of the experts could you please help me clarify in order to ask the right question?
0
 
LVL 16

Assisted Solution

by:Wasim Akram Shaik
Wasim Akram Shaik earned 500 total points
ID: 40432035
The   PS_TXN table stores snapshots of pending changes made to BC4J application module instances.

,simply doing a blind delete or truncate without knowing the impact will simply make your changes lost. Also you may get some unexpected errors(error while inserting a record in PS_TXN table) as there is a sequence which is being used by the table and it is assigned to specific session while the application is running.

However if you refer docs, there are ways to delete the rows, there is an api which will do this task, so its safe to use an api which will decide the best way to delete the rows(inactive and older than specific date)

See the link below for illustration of the cleanup script

http://www.oracle.com/technetwork/developer-tools/jdev/overview/bc4j-temp-tables-087270.html#ID516
0
 
LVL 1

Author Comment

by:JavierVera
ID: 40436709
hello Wasim Akram Shaik, i've read the link and there it says Oracle itself provides a script to achieve the maintenance of these table and sequence, would you recommend to clear for example every registry wich is over 2 days old ?? (most of these apps are for reporting read only use, so i belive there is no sense on having such a FAT table PS_TXN)
On the other hand, wich one could you consider as your best practice?
Thank you!
0
 
LVL 16

Accepted Solution

by:
Wasim Akram Shaik earned 500 total points
ID: 40436798
>>2 days old

I really cannot predict the amount of the data with which the temp table is loaded in your environment, for huge transactions(which we have in our environment like around 1  million/day) we use to purge them daily(during the lean period). Some would do it weekly(for pre-prod), bi-monthly(sit/uat) etc., it all depends on the incoming you have..
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This post first appeared at Oracleinaction  (http://oracleinaction.com/undo-and-redo-in-oracle/)by Anju Garg (Myself). I  will demonstrate that undo for DML’s is stored both in undo tablespace and online redo logs. Then, we will analyze the reaso…
These days socially coordinated efforts have turned into a critical requirement for enterprises.
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now