Home » SQL & PL/SQL » SQL & PL/SQL » DB last date (12.1.0.1.0)
DB last date [message #685782] Wed, 23 March 2022 05:52 Go to next message
OraFerro
Messages: 405
Registered: July 2011
Senior Member
Hi All,

I restored a backup to a testing DB. Let's say the backup was named (1 Jan 2022), however the data made me suspect that the label is wrong especially that the backup file OS date is later than 1 Jan 2022.

My question: is there a way I can know the date of the last transactions that took place on the DB? Is there a system table that keeps the last transaction date or the dbump date for example?

Thanks,
Ferro
Re: DB last date [message #685783 is a reply to message #685782] Wed, 23 March 2022 06:26 Go to previous messageGo to next message
Michel Cadot
Messages: 68227
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

What do you mean by "last transaction"? last ended? or current ones also?
What is your "date of the transaction"? Start time? End time?
Ended transactions are in the logs (online and archived);
Current transactions are in v$transaction.

Re: DB last date [message #685786 is a reply to message #685783] Wed, 23 March 2022 23:28 Go to previous messageGo to next message
OraFerro
Messages: 405
Registered: July 2011
Senior Member
Hi Michel,

I mean the last transaction that already took place and ended, not the current one.
What I want is to make sure that this backup belongs to the date it suppose to. So if the backup labeled date is 1 Jan 2022, the last transaction that already took place should not exceed this date, else the backup labeled date is wrong. This is why v$transaction wont help.

Thanks,
Ferro
Re: DB last date [message #685787 is a reply to message #685786] Thu, 24 March 2022 01:20 Go to previous messageGo to next message
Michel Cadot
Messages: 68227
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

So use Log Miner.

Re: DB last date [message #685788 is a reply to message #685782] Thu, 24 March 2022 07:34 Go to previous message
EdStevens
Messages: 1375
Registered: September 2013
Senior Member
how are you taking your backups? Why would the date in the backup file name NOT be correct? If you are using rman (as you should) why do you care? Rman will manage the file names, and know what is what. With online backps in archivelog mode, you can always restore/recover to a specified point in time.
Previous Topic: Code not waiting for REFCURSOR
Next Topic: ORA-01722 Invalid Number for numeric values.
Goto Forum:
  


Current Time: Thu Jul 07 02:58:28 CDT 2022