Home » RDBMS Server » Backup & Recovery » importing last 3 months of data (19c)
importing last 3 months of data [message #685838] Tue, 05 April 2022 15:44 Go to next message
varunvir
Messages: 389
Registered: November 2007
Senior Member
Hi Experts,
Is it possible using expdp to copy last 3 months of data from db into a new database?
or

Is it possible to import last 3 months to new database into new database using RMAN?

Thanks,
Varun
Re: importing last 3 months of data [message #685839 is a reply to message #685838] Wed, 06 April 2022 00:45 Go to previous messageGo to next message
Michel Cadot
Messages: 68624
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

Yes, no, maybe. It depends on your data or db architecture.

Are you able to determine the last 3 months data?
Have you a current date column in your tables?
Are your data in tablespaces depending on months, like partitioning by month?
...

Re: importing last 3 months of data [message #685843 is a reply to message #685839] Wed, 06 April 2022 08:05 Go to previous messageGo to next message
varunvir
Messages: 389
Registered: November 2007
Senior Member
Hi Michel,

Are you able to determine the last 3 months data? yes
Have you a current date column in your tables? yes
Are your data in tablespaces depending on months, like partitioning by month? yes

Can I use feature flashback_time with expdp to extract 3 months of data?

Thanks,
Varun
Re: importing last 3 months of data [message #685844 is a reply to message #685843] Wed, 06 April 2022 08:40 Go to previous messageGo to next message
Michel Cadot
Messages: 68624
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

Quote:
Can I use feature flashback_time with expdp to extract 3 months of data?

No, it is the opposite you could use it to extract all but the last 3 months of data.

But you may use the QUERY parameter, something like:
QUERY="WHERE date_col BETWEEN add_months(sysdate,-3) AND sysdate"
[Edit:missing word]

[Updated on: Thu, 07 April 2022 00:15]

Report message to a moderator

Re: importing last 3 months of data [message #685853 is a reply to message #685844] Wed, 06 April 2022 15:18 Go to previous messageGo to next message
varunvir
Messages: 389
Registered: November 2007
Senior Member
Thanks Michel
Re: importing last 3 months of data [message #685854 is a reply to message #685843] Wed, 06 April 2022 15:51 Go to previous message
EdStevens
Messages: 1376
Registered: September 2013
Senior Member
Quote:
Are you able to determine the last 3 months data? yes
How are you able to make this determination? Do all of your tables include something like a 'last_update_date' column? Even tables where the data is not 'dated', is rather static, but still important, like lookup tables . . .

[Updated on: Wed, 06 April 2022 15:52]

Report message to a moderator

Previous Topic: restore 11g to 19c using rman
Next Topic: 10gR2 -> 19c
Goto Forum:
  


Current Time: Thu Mar 28 07:19:50 CDT 2024