It is not easy to process tens of millions of records in Oracle. The following describes how to insert and query tens of millions of records in Oracle.
Recently, we have implemented a project to perform insert and query operations on database
% Type, % rowtype in oracle
1. Use % TYPE
In many cases, PL/SQL variables can be used to store data in database tables. In this case, the variable should have the same type as the table column. For example, if the first_name column type of the
BecausePreviousThe pipeline table function writing is a bit rough. add an article for your convenience. The two functions initialize the function data of the pipeline table. Therefore, the function is designed to call another function to obtain the
1. Score by ROWID Select * from t_xiaoxi where rowid in (select rid from (select rownum rn, rid from (select rowid rid, cid fromT_xiaoxi order by cid desc) where rownum 9980) order by cid desc; Select * from t_xiaoxi where rowid in (select rid
UnionSelect * from emp where deptno = 10 union select * from emp where deptno = 20;Select * from emp where deptno = 10 union all select * from emp where deptno = 20;Select * from emp where ename like '% A %' or ename like '% M % ';Select * from emp
OEM:Http: // full computer name: 5500/em/
Sys/System managerScott tiger1. Forget the logon password of a user except SYS and SYSTEM.Log On As a sys (or SYSTEM) user.Conn sys/PASS_WORD as sysdba;Use the following statement to modify the user
Oracle recursive query and deletion of parent-child relationship recordsThe database often processes records of parent-child relationships. In oracle, you can use a query statement to retrieve all the sub-records at a time. Example: t1 t11 t111 t1111
Add columns automatically for building: create sequence emp_sequence increment by 1 ---- add several minvalue 1 at a time ---- the minimum value is 1 nomaxvalue ---- do not limit the maximum value start with 1 ---- cache 10 from 1 ---- cache
Oracle time-type query Oracle query date can use =, but the data types must be consistent on both sides of the equal sign, for example, '2014-9-19 'is a string that cannot be directly compared with a date field and must be converted to a date string
The basic function of transactions in the database is to switch the database from the consistent state to another consistent state, the transaction isolation level defines how sensitive a transaction is to the modifications made by another
Automatically add a partition stored procedure for a partition table: the SQL code create or replace procedure guan_add_partition/* automatically adds partitions for all partition tables under a user. the partition column is of the date type. The
Oracle-Example of modifying the field type: l_amount_temp is a temporary field, and L_AMOUNT is a field to be modified. SQL code alter table alter add l_amount_temp int; www.2cto.com alter table modify L_AMOUNT NULL; update into set l_amount_temp =
SQL code -- Create table (create partition table) Create table BILL_MONTHFEE_ZERO (www.2cto.com SERV_ID NUMBER (20) not null, BILLING_CYCLE_MONTH NUMBER (6) not null, DATE_TYPE NUMBER (1 ), ACC_NBR VARCHAR2 (80) partition by range (partition)
The oracle database query and index creation system contains a log table that records logon and logout. After a long time, the data volume is large and there is no historical table. When the client logs on, it will go to the database to query the IP
After a piece of SQL code is written, you can view the SQL Execution Plan To preliminarily predict the performance of the SQL statement at run time, especially when the efficiency of an SQL statement is found to be poor, we can view the execution
Oracle modifies the Data Type of a field in three ways: 1. set this column to null and modify its type (this will result in data loss. the simplest method is to assume that your table is named tab_target create table test as select * from tab_target
Oracle Real-Time Interpolation Speed suddenly slows down problem solution a warehouse receiving program is written in the work, which is responsible for real-time unpacking, parsing, and inserting SQL statements into the Oracle database.The average
In the Oracle trigger, select into reports no_data_found Exception Handling. In red, create or replace trigger TIG_MONITOR_ALARM after insert on failed for each row www.2cto.com declare -- standard value number; -- Alarm fact table id liveid number;
In Oracle, The REGEXP_SUBSTR function in Oracle is described as follows: in oracle, '17, 20,23 'is split into '17', '20 ', '23. REGEXP_SUBSTR function Format: function REGEXP_SUBSTR (String, pattern, position, occurrence, modifier) _ srcstr: String _
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