The following process is implemented in 9i:Declare type t_rn is table of TMP. rn % Type Index by binary_integer; type t_ran is table of TMP. num % Type Index by binary_integer; rn t_rn; ran t_ran; cursor cur_num is select rownum, trunc
This article uses a simple example to illustrate how to write a ruby script to perform Oracle database operations. The main steps are as follows:
1. Download Ruby at the following address:
Http://www.ruby-lang.org/zh_CN/downloads/Here we
First, we need to clearly understand how we know that indexes are not used in an oracle SQL statement. By displaying the execution plan of SQL statements, you can know how the entire SQL statement is executed step by step in Oracle.Second, analyze
There are five main types of loops: exit when, loop, while, for (Common loop), and for (cursor loop). The following is an example to illustrate (all stored procedures ).
1. Exit when loop:Create or replace procedure proc_test_exit_when isI
I wrote TMD tricks on the Internet.
Idea: PLSQL depends on OCI. dll and some other files in the client, so it must be provided.
Locate listener. ora through the Environment Variable tns_admin,Tnsnames. ora to establish a connection.
Steps:
1.
Envirement: Windows XP, Oracle 10g
Problem: When I open the EM browser, it shows that: "The database status is currently unavailable. it is possible that the database is in Mount or nomount state... "Then I go to start up, I input the OS and
1. Complete database backupExpSystem/password @ SidFull = y file = D:/system. dmp log = D:/system. Log
2. Data warehouse receiving(A) Delete SDE and SDE user from the databaseDrop user SDE cascade;Drop user sdeuser cascade;(B) Create a New SDE user
A user-defined function is a code block stored in a database. It can return the value to the calling program. The call is like a system function, such as a max (value) function. value is called a parameter. There are three types of function
1,Ceil (N)Function: Take a value greater than or equal to a value.NThe smallest integer
2,Floor (N)Function: Take a value less than or equalNThe maximum integer
3,InstrAndLimit B: Query the position of the target string in the source
I,$ VI $ ORACLE_HOME/Network/admin/sqlnet. ora
If the sqlnet. ora file does not exist, generate the file as follows:
1) You can copy $ ORACLE_HOME/Network/admin/samples/sqlnet. ora to the $ ORACLE_HOME/Network/admin/directory.
2) use the netca tool
I. syntax and Principles of the update Statement 1. Syntax single table: Update table name set column name = new value where column name = A value such as: Update t_join_situationset
Join_state = '1' whereyear = '000000' the join_state field of the
Document directory
Tables and columns
Integrity constraints
View
Sequence
Synonym
Index
User
Role
Tablespace quota
Configuration table
Tablespace
Data Files
Segment
Rollback segment
1. System Table
System Parameters of the Oracle
From: http://blog.csdn.net/xuanxingmin/article/details/4266327
Oracle case statement
Currently, Oracle supports two case representation methods. One oracle is called simpleCase (simple form), and searched case (Query Form ). SimpleCase is
From: http://www.cnblogs.com/zjrstar/archive/2006/08/31/491090.html
Parsing Oracle rownum
For rownum, it is the number that the Oracle System sequentially assigns to the row returned from the query. The first row is allocated 1, and the second row
Create user _ authorization _ in Oracle and import data
Complete process: create users, create tablespaces, authorize, and create tables
L create a user
Create user BBS identified by bbs123;
L create a tablespace
A project needs to monitor data changes in a table, and then generate a file to the disk based on the change results to facilitate monitoring by log capturing programs.
You need to use the util_file package that comes with Oracle.
The target
Queryoptimizer has gone through two historical stages: RBO andCBO. In the RBO era, Oracle execution plans are generated through a series of solidified rules. In the CBO era, system statistics are used to test various execution paths and obtain
Oracle stored procedures support arrays, which greatly improves the performance of batch data operations. If you need to insert 1000 records, the test_info table structure is:
--------------------------------------------------------------------
Id_
Oracle has two optimization methods when executing SQL statements: Rule-Based RBO and cost-based CBO. The Oracle parameter optimizer_mode determines the optimization method used during SQL coaching.
Rule Based optimizer (RBO) based on RulesCost
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