Moving audit Records from one database to another database using dblink
i got five database, i have to move sys.aud$ records from five databases to one centralized database into another schema every day at 10:00 clock, i have to use a dblink for this, i have to create same table as sys.aud$ with different schema in centralized database with one extra column db_unique_name,by using db_link how i need to move records from all the five databases to one centralized database, can anyone help me here how to create a db_link from to move records from five database to one centralized database, due to maintainance perspective i have to move the records from all the five databases to one centralized database. i have to write a script for moving the audit records from all the five databases to one centralized database, can anyone help me how to write the script, or if you have any related scripts , can u post here, it will helpful for me.
spool audit.log
--"Auditing Initialisation Parameters: check initialization parameter"
select name || '=' || value from v$parameter where name like '%audit%'
---"if auditing is disabled then issue this command and bounce"
alter system set audit_trail=db,extended scope = spfile
shutdown immediate
startup
create tablespace ORDER_DATA datafile '+DDATA' size 50m;
create user INFO identified by INFO;
Grant connect,resource to INFO;
Alter user INFO quota unlimited on ORDER_DATA;
create table INFO.ORDER as select * from sys.aud$;
alter INFO.ORDER add db_unique_name varchar2(50);
create table INFO.ORDER
partition by range (Timestamp#)
subpartition by hash(dbid)
subpartition template
(subpartition sp1 tablespace users,
subpartition sp2 tablespace users)(
partition p1 values less than (TO_DATE('07/29/2010','MM/DD/YYYY')),
partition p2 values less than (TO_DATE('07/29/2011','MM/DD/YYYY')),
partition p3 values less than (MAXVALUE)) tablespace BGORDER_DATA as select * from sys.aud$
spool off;
exit
BEGIN
DBMS_SCHEDULER.create_job(
job_name => 'Move Aud$ records',
job_type => 'PLSQL_BLOCK',
job_action => 'CREATE OR REPLACE PROCEDURE bgorder_aud
AS
ts TIMESTAMP;
BEGIN
ts := SYSTIMESTAMP;
insert into info.order select * from sys.aud$ where timestamp# < ts;
delete sys.aud$ where timestamp# < ts;
commit;
END;
start_date => TRUNC(SYSDATE) + 22 / 24,
repeat_interval => 'FREQ=daily;BYHOUR=22;BYMINUTE=0;BYSECOND=0',
enabled => TRUE,
comments => 'Move records');
END;
/
Similar Messages
-
Select records from one database and insert it into another database
Hi
I need to write a statement to select records from one database which is on machine 1 and insert these records on a table in another database which is on machine 2. Following is what I did:
1. I created the following script on machine 2
sqlplus remedy_intf/test@sptd @load_hrdata.sql
2. I created the following sql statements in file called load_hrdata.sql:
rem This script will perform the following steps
rem 1. Delete previous HR data/table to start w/ clean import tables
rem 2. Create database link to HR database, and
rem 3. Create User Data import table taking info from HR
rem 4. Drop HRP link before exiting
SET COPYCOMMIT 100
delete from remedy.remedy_feed;
commit;
COPY FROM nav/donnelley@hrp -
INSERT INTO remedy.remedy_feed -
(EMPLID, FIRST_NAME, MI, LAST_NAME, BUSINESS_TITLE, WORK_PHONE, -
RRD_INTRNT_EMAIL, LOCATION, RRD_OFFICE_MAIL, RRD_BUS_UNIT_DESCR) -
USING SELECT EMPLID, FIRST_NAME, MI, LAST_NAME, BUSINESS_TITLE, WORK_PHONE, -
RRD_INTRNT_EMAIL, LOCATION, RRD_OFFICE_MAIL, RRD_BUS_UNIT_DESCR -
FROM ps_rrd_intf_medium -
where empl_status IN ('A', 'L', 'P', 'S', 'X')
COMMIT;
EXIT;
However, whenever I run the statement I keep getting the following error:
SP2-0498: missing parenthetical column list or USING keyword
Do you have any suggestions on how I can fix this or what am I doing wrong?
Thanks
AliThis doesn't seem to relate to Adobe Reader. Please let us know the product you are using so we may redirect you or refer to the list of forums at http://forums.adobe.com/
-
I bought a new laptop and used Windows Easy Transfer cable and moved all files from one computer to another. I installed iTunes and found my iTunes music Library. However, when I plug in my iPod it says it is already synced with another iTunes Library.
I don't see anything in Help that shows when you already have transfered all the files over. Why would it want to erase and sync when I already have all the music folder copied over? I didn't have an issue when I had another technician copy from one laptop to another. Home sharing is also on but not being recognized.I suspect you only migrated the media folder instead of the complete working library. Either review the transfer process and copy over the entire iTunes folder from your old profile's music folder or see Recovering your iTunes library from your iPod or iOS device.
tt2 -
I have over 200 hours of HD video on 5 different TB Thunderbolt GRaid hard drives. I need to reorganize my projects, moving large files from one drive to another. Advice?
Do some testing to get your method working right with some less than important footage.
Copy/paste files where you want then.
Use the FCE Reconnect feature to tell FCE where the newly copied files reside.
Make sure the new location and files are working as expected with your Projects.
Delete the original files if no longer required.
Al -
Re: Transferring records from one request to another.
Hi Guys,
Currently the pseudo delta is loaded with posting date selection as two months(say, may and june- 2 lakh records).
Every two months once we do full update (3 million records).
every day we delete the delta request and load data, the full load request will be available.
for some reason, i want to move few data available in the delta request to full update request. bcoz i have done changes in the routine level, which adds up new record to dso. I want to move these added records to full update request. Bcoz the delta request is deleted daily and loaded. I dont wnat my changes to be executed daily. Bcoz the changes i done in routine level takes more time to complete the dtp.
Is it possible to move selected records from one request to another? If yes, i will move the record to full update and revert the routine change. so that my data load will be faster.
Regards,
AnandClose
-
Moving multiple queries from one category to another in QM
Hi All,
Is there is any way of moving multiple queries from one category to another in the query manager?
Or is the only way of doing it by saving each one individually into a different category.
Any ideas ?
Regards,
Rakesh NHi Rakesh,
The query manager has limited function compare with normal file management applications. Under current design, you have to do this one by one. You just need to make sure move the smaller amount of queries to large category. Category name can be changed easily.
Thanks,
Gordon -
Problem: Focus got lost, while moving from one cell to another cell using tab key.
Example: In an AdvanceDataGrid, there are three columns having custom ItemRenderer with Spark TextInput control (editable=true & focusEnabled=true).
When I try to move the focus in with in 2nd, 3rd & 4th column using tab key, focus got lost. Most of the time it’s working, but some time it doesn’t work. There’s no clue as to how may rows/columns the focus has jumped to; or whether the focus has gone out of the data grid altogether.
Observations: I am not sure whether this problem is because of custom component implementation or it is because of some issue related to Flex Component.
It only occurs when we perform some actions like some server call, some complex logic execution etc. at the focus out event of itemrenderer.
There is one property of datagrid i.e. editedItemPosition which contains row & column index of datagrid. On the focus out event, it gets null when focus got lost. We tried to set it, but it didn’t work.
Steps Performed:-
1. Currently focus is in 2nd column i.e. Apply to #.
2. Once I press tab key from 2nd column, it goes to 3rd column which is correct.
3. Now if I press tab key from 2nd column i.e. Payment #, focus should go to 3rd column, but it goes out of data grid and set the focus of button which is outside data grid.http://search.java.sun.com/search/java/index.jsp?qp=&nh=10&qt=%2Bjtable+%2Btab+%2B%22enter+key%22&col=javaforums
-
If i transfer some records from one server to another server,
hi to all......
5........If i transfer some records from one server to another server, will that save in change request or work bench request?
thanks and regards,
k.swaminathHi friend my suugession is , if u r transfering records from one client to another or changing anything in the active pgm, it will save under change request...
But if u r transfering records from one server to server it will save under work bench request... -
Best Way to port the data from one DB to another DB using Biztalk
Hi,
please suggest best way to move the data from one db to another DB using biztalk.
Currently I am doing like that, for each transaction(getting from different source tables) through receive port, and do some mapping (some custom logic for data mapping), then insert to target normalized tables(multiple tables) and back to update the status
of transaction in source table in sourceDB. It is processing one by one.
How/best we we can do it using bulk transfer and update the status. Since it has more than 10000 transaction per call.
Thanks,
VinothHi Vinoth,
For SQL Bulk inserts you can always use SQL Bulk Load
adapter.
http://www.biztalkgurus.com/biztalk_server/biztalk_blogs/b/biztalksyn/archive/2005/10/23/processing-a-large-flat-file-message-with-biztalk-and-the-sqlbulkinsert-adapter.aspx
However, even though a SQL Bulk Load adapter can efficiently insert a large amount of data into SQL you are still stuck with the issues of transmitting the
MessageBox database and the memory issues of dealing with really large messages.
I would personally suggest you to use SSIS, as you have mentioned that records have to be processed in specific time of day as opposed to when the
records are available.
Please refer to this link to get more information about SSIS: http://msdn.microsoft.com/en-us/library/ms141026.aspx
If you have any more questions related to SSIS, please ask it in
SSIS
forum and you will get specific support.
Rachit -
How to move folders from one server to another serve using unix command
Hi All,
How to move the folders from one server to another server using unix command.
scp -r armops@sjarmprd01:/ARM/scripts [email protected]:/ARM/scripts/
but it is giving an error like not a regular file .. what it means .. please let me know if any one knows about it
Thanks
Sreedharnot a regular file .. what it meansProbably you have some fifo (named pipe) files...
Said that this has nothing to do with database (you should post on some nix forum, for example http://forums.oracle.com/forums/forum.jspa?forumID=135), you may try rsync* command (man rsync). -
Can I transfer info from one macbook to another by using a firewire cable?
Can I transfer info from one mac to another by using a firewire cable?
You can boot the computer that you would like to get the file from into target disk mode.
This document will help you.
http://docs.info.apple.com/article.html?path=Mac/10.6/en/8443.html -
How do I transfer files from one computer to another without using cables??
How do I transfer files from one computer to another without using cables?
Wifi network
Email
Thumb Drive
Online storage such as, iCloud Google Docs, SkyDrive, etc. -
How to transfer songs from one iPad to another iPad using iTunes?
How to transfer songs from one iPad to another iPad using iTunes?
You can't without a third party app. If you didn't purchase the Music with your Apple ID or if the music was imported from CD's on your friends iTunes library, syncing will not work ....nor will transferring purchases.
Look at this app .... TouchCopy
http://www.wideanglesoftware.com/touchcopy/index.php -
Moving a Company from one server to another server
Dear All,
I have gone through all the SBO SDN Threads (related to SBO-Common) to know the role of SBO-Common data base in SAP B1, but the following case is still not clear to me. Please help.
Suppose I have two SBO servers (of same settings) as follows u2013
Server1:
Database Company
SBO-Common N/A
SAP_Abc_Co Abc Co.
Server2:
Datebase Company
SBO-Common N/A
SAP_Xyz_Co Xyz Co.
Now I want to transfer the above said Xyz Co (database-SAP_Xyz_Co) from Server2 to the Server1 (keeping all other companies in Sever1 intact). How to do it?SBO-Common, also acts as the license server.
To transfer a company from one server to another you can do like Steffen said.
You don't need to backup SBO-Common.
Dan Souza - EasyOne Consulting
[www.easyone.com.br|http://www.easyone.com.br/] -
How to move records from one table to another?
Is there a way to copy data and column names from one table to another table?
I am trying to copy one production database table onto the development database. we are using Oracle 10g. I tried exporting to an xls file and importing to the other table but this needs to create destination table with the column names. Is there any better approach to achieve this?Hello,
You can create dblink between production and dev and from dev just
*1. create table mytable as select * from mytable@dblink;**2. Use of export/import or datapump*
Example
On prod
exp username/password tables=mytable1,mytable2 file=mytableexport.dmp log=mytableexport.log
On dev
imp username/password tables=mytable1,mytable2 file=mytableexport.dmp log=mytableimport.log*3. Datapump*
http://www.oracle-base.com/articles/10g/OracleDataPump10g.php
*4. Generate csv formatted file and use sqlldr or external*
External Table: http://www.adp-gmbh.ch/ora/misc/ext_table.html
Sqlldr: http://www.psoug.org/reference/sqlloader.html
Regards
Edited by: OrionNet on Feb 13, 2009 6:52 PM
Maybe you are looking for
-
When Microsoft Internet Explorer was my browser the dial-up connection screen to my internet service provider would come up automatically when I launched the browser. Now that I have made Mozilla Firefox my default browser this no longer happens. Lau
-
Hello The problem we are facing is.. We have installed the recent patch in order to get TAN included in Form 16 and it is working fine in r/3 but in ESS it is throwing dump error. The error states : Error in Abap 4 statement when processing an intern
-
installed adobe flash 13 and i cant watch any videos i uninstalled it installed it and the f-ing adobe pagesays its missing a plug in and im looking at the plugins and lo and behold its plugged in and i downloaded mavericks about a week ago the funny
-
JRE 5 and Mozilla-1.7.3 question
Is there anybody that can get Java 5 to work with mozilla-1.7.3. I'm using Redhat Fedora core 2 and cant get the symlink solution to work on my updated mozilla. I have installed jre-1.5.0 and tried all previous versions with no luck. I'm really confu
-
Can't download purchased music - no option available on Purchased link
Hi All, I've just bought a new mac. I started to move files across from my Windows PC via memory stick. Long story short i've managed to delete some of my purchased content. I managed to recover some of the files directly from my ipod, but others