Is there any way to retrieve older version of changed view on pl/sql oracle developer?
I really dont know where to start atm. Its not materialiazed view
CodePudding user response:
The database doesn't keep a history of object definitions.
However, any good development process will involve a change control and versioning system. Hopefully your database objects are being tracked as files in a Git repo somewhere.
If not, your DBA could probably get the previous version of your VIEW from a backup, or by mining the redo/archive logs.
CodePudding user response:
A view is just a stored query. If you replaced it with a new version, the old one is lost.
A few options:
- check your version control system
- restore it from backup
- either of filesystem files or
- database backup, be it RMAN or even .dmp file (as result of data pump export)
- if you dropped it, see whether you can get it by flashback query on DBA_VIEWS
- is it in Recycle bin?
If nothing of this help, huh, you're probably out of luck.