This method enables synchronization of tables with two different versions of Oracle, and is more efficient than IMP statement-guided DMP.
first, achieve the goal:To implement data synchronization from the source table (AAA) to the target table (BBB).
Primary database
ip:192.168.2.100
Db:rdbms 11.2.0.4
Oracle_sid:test
Global_name:test
From the database
ip:192.168.2.14
Db:rdbms 11.2.0.4
Oracle_sid:orcl
Global_name:orcl
1 for test, ORCL Library to open archive2 Configure the TEST,ORCL library
--① System Change number--Gets the data time insertion time ORA_ROWSCN the SCN that returned the last modification of the row.
Select Scn_to_timestamp (ORA_ROWSCN), tt.* from TT;
--SCN and timestamp convert select TIMESTAMP_TO_SCN (sysdate) from
1. Start Sqlplus2. Please enter your username: Sqlplus/as sysdba3. Enter Password: direct return(Note: For SYS both lock and not lock can be locally certified log into SYSDBA)4. Connect to:Oracle Database 11g Enterprise Edition release
Today encountered ORA-12560:TNS: Protocol adapter error problem, after a few efforts to solve the problem, and share with you.
There are three reasons for the problem with Ora-12560:tns: Protocol Adapter errors:
1. The monitoring service did not
rownum
It is possible to know that rownum only applies to less than or less than equals, and if it is equal to judgment, it can only be equal to 1 and cannot be compared more than.RowNum is the number that the Oracle system sequentially assigns to
1. Basic Grammar
SELECT * from table [start and Condition1]
connect by [prior] Id=parentid1
It is commonly used to find data that has a parent-child relationship, that is, a tree-structured data, and its return data can clearly differentiate
Oracle Read the comments list, first three by the number of points, and then sorted in reverse order of creation time, required pagination:
The first way:
SELECT * FROM (select b.*, DECODE (rownum, 1, 1, 2, 2, 3, 3, 4) rankFrom (SELECT a.*From
Oracle time and date operationsSysdate+ (5/24/60/60) Delays 5 seconds based on system time
SYSDATE+5/24/60 delays 5 minutes based on system time
SYSDATE+5/24 delays 5 hours based on system time
SYSDATE+5 delays 5 days based on system time
Add_months
original works, from the "Deep Blue Blog" blog, Welcome to reprint, please be sure to indicate the following source, otherwise held responsible for copyright liability.
Blue blog:http://blog.csdn.net/huangyanlong/article/details/43926321.
First
The database connection is timed to see if the number of sessions is normal. Set up too many data links to consume the resources of the database
For some hung connections, a manual kill is required
Select Sid,serial#,username,program,status from V$
Such as:
Cursor C_columns (t_table_name varchar) is select column_name from user_tab_columns WHERE table_name = T_table_name Order b Y table_name,column_id;
V_txt1:= ';For V_col in C_columns (V_tablename) loop--use a For loop to traverse cursor
The cursor (cursor)--the cursor is a data buffer that the system opens for the user, and holds the execution result of the SQL statement. Each cursor area has a name that allows the user to retrieve the record from the cursor in one of the SQL
1, change the client character set: run regedit through Windows Run menu, modify registry
Start-> Run-> rededit
Under Registry Editor-> HKEY_LOCAL_MACHINE-> SOFTWARE->oracle->key_xe->right WINDOW DOUBLE CLICK Nls_la NG-> Change VALUE to
I. Permissions-related
1. Landing
Sqlplus System/admin as SYSDBA; Administrator Login System Account
Sqlplus Scott/tiger; Log on to regular user Scott
2. Managing Users
Create user Wahaha; Under the Administrator account, create a user
Sequence (SEQUENCE)
A sequence is a database object that can be used to generate a unique integer. The main code value is generated automatically by using a sequence.
The value of a sequence is automatically generated by a special Oracle program, so
When you need to use these 2 times, first of all, simply:
If you order the monthly product of March 15, the end of the month, then you should charge a 17-day fee, this time should determine whether the order time is greater than the beginning of the
If Oracle sets a certain time without access, the connection is automatically closed so that an IO exception occurs when Java accesses Oracle again.Workaround: Add the following configuration information to the spring configuration
Oracle 11g introduces snapshot Standby, which allows Standby database to be opened in Read-write mode. When switching back to standby mode, all modifications in the Read-write mode are lost. It is implemented through the flashback database, but
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service