1, Oracle users add
Copy Code code as follows:
Create user Lisi identified by Lisi;
Note: Create user is creating database users, followed by user name, identified by is set user password
2, the "connection" database
1. Turn off all Oracle services. Can be shut down in Windows Services Manager;2. Open the registry: Regedit Open the path:Hkey_local_machine\system\currentcontrolset\services\ removes all Oracle-initiated service names under this path, which
Cause
This error occurs when you do hibernate BULK Insert Org.hibernate.QueryTimeoutException:
The reason for the error is that the capacity of the table space is insufficient and the space capacity needs to be increased. The first thought was to
First, if it is just deleted, then there are two ways:
First with show parameter undo; command to view the database parameter undo_retention settings at that time.
The display is as follows:
Copy Code code as follows:
1. Various procedures for application-level shutdown.
2. Stop Oralce Listening process:
$lsnrctl stop
3. Under the exclusive system user, back up the control file:
Sql>alter database backup controlfile to trace;
4. Under exclusive system users,
The Union and the Union all work together to combine SELECT query result sets, so what's the difference?
The Union merges the resulting set of queries and then checks them to remove the same rows. Disadvantage: low efficiency;
The union all is only
In is mainly used for incoming parameters, can be variables, constants, expressions, within the subroutine can not change its value.
Copy Code code as follows:
DECLARE
N Number: = 10;
PROCEDURE do_something (
N1 in (number) is
Here are some of the hard working processes in the background. System Monitor,smon, Progress Monitor (process Monitor,pmon), database writer (db writer,dbwn), log recorder (logs WRITER,LGWR), Checkpoint process (Checkpoint process,ckpt)
1, Smon:
The first scenario is that the returned cursor is the data for a specific table or view, such as:
Sql-code:
Copy Code code as follows:
CREATE OR REPLACE PROCEDURE P_testa (
PRESULT out Sys_refcursor
)
As
BEGIN
OPEN PRESULT
Oracle Database backup:
--Keep the backup record of the most recent week;= = = Text:= = Start ==============
Copy Code code as follows:
Echo Set backup file Folder ...
Set "Tbuf=e:\cway\backup"
echo Sets the backup file name (named
One: use where less to use having;
Second: Check more than two tables, the record less on the right;
Third: Reduce the number of visits to the table;
Four: When there is a subquery, the subquery is placed in the front;
V: try to avoid using the *
This is written for Oracle, can be used on different computers, because it will automatically read the current computer environment variables, so as to obtain the Oracle installation path, the only point is that the program is running in the process
SQL statements for querying and deleting duplicate records
1, look for redundant records in the table, duplicate records are based on a single field (Peopleid) to judgeSELECT * from People
where Peopleid in (select Peopleid from People GROUP by
1, Telnet to the remote database server
Cmd>telnet The remote database IP
2, switch to the database users
Dqxxdbs01:/> su-oracle
3, access to the database with super users
$ sqlplus "/as sysdba"
4, check the parameters, whether you can use the job
In the development process, may use the Oracle sequence statement, this article takes the Oracle sequence statement how resets carries on the introduction, needs the friend to be possible to refer to under
Oracle Reset sequence Statement 1
SQL code
Serveroutput is a sqlplus configuration parameter, not a database configuration parameter, modifies and saves sqlplus configuration parameters, so you do not have to reset each time you open the Sqlplus.
Set the method as follows:
1. sql> Set
Sql:charindex (' String ', field) >0 charindex (' Administrator ', Muserid) >0
Oracle:instr (field, ' String ', 1,1) >0 InStr (Muserid, ' Administrator ', 1,1) >0
In the project to use the Oracle INSTR this function, by the way carefully learn
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