Management of Oracle databases

--View of database nameSelect name from V$database;650) this.width=650; "src="%5c "alt=" spacer.gif\ "/>--View of instance nameShow parameter instance_name;650) this.width=650; "src="%5c "alt=" spacer.gif\ "/>--Data filesSelect name from V$datafile;-

Oracle Archiving Mode settings

A set of SQL code for archive modesql> archive log list;#查看是不是归档方式Sql> alter system set LOG_ARCHIVE_START=TRUE Scope=spfile;#启用主动归档Sql> alter system set log_archive_dest= "Location=/oracle/ora9/oradata/arch" scope=spfile;#设置归档路径Sql> alter system set

ORACLE functions NVL, NVL2, Nullif

NULL refers to a null value, or an illegal value.1, NVL (expr1, expr2) functionEXPR1 is null, returns EXPR2, is not NULL, returns EXPR1. Note that the two types should be consistentEg:select NVL (column,0) from DUAL--column value is null, it is

Grouping sort in Oracle takes top N

Data processing in the database, it is often necessary to get top N for a certain class, which involves grouping group by and sorting order by, then according to RowNum to obtain the first few data, the Oracle Database Row_number () over function

Exception Handling Methods in Oracle

Exception handlingCreate or replace procedure Prc_get_sex(Stuname Student.name%type)AsStusex Student.sex%type;BeginSelect Sex to Stusex from student where name=stuname;Dbms_output.put_line (' Students ' | | stuname | | ' The sex is: ' | |

MyBatis BULK Insert (Oracle)

configuration file ( Oracle ): BULK Insert temporary table -INSERT into Ce_tempphone_info (phone)(Select #{item,jdbctype=varchar} from dual)Insert intoce_tempphone_info (phone) (select XXX from dual union select yyy from dual ...);

"Oracle Services"

After installing Oracle, we can go to the service and see several more Oracle services,650) this.width=650; "id=" aimg_ifb4b "class=" Zoom "width=" "height=" "src=" http://dl2.iteye.com/upload/ Attachment/0105/7934/4858e4ce-5cb4-340b-b040-806be8907e4

ORACLE Paging SQL

This SQL paging is simple, but is often used to query large amounts of data.SELECT * FROM (select A.*,rownum RN from (SELECT * from table_xx) A WHERE ROWNUM =11 This SQL is efficient because in optimization mode, Oracle can push the outer query

Oracle stored procedure Basic syntax

Line 1:Create OR REPLACE PROCEDURE is an SQL statement that notifies the Oracle database to create a stored procedure called skeleton, overwriting it if it exists;Line 2:The IS keyword indicates that a PL/SQL body is followed.Line 3:The BEGIN

Oracle connects two results to query, resulting in a federated result of two queries

First, the demandUser answer, a total of 3, must be 3 questions are completed to submit.Objective: To query the user answered several questions correctly, answered several wrong questions. (Of course, you can only find the correct number of

Oracle CASCADE DELETE Trigger

CREATE TABLE STUDENT (--Creating student tablesID Number (TEN) PRIMARY key,--primary Key IDSNAME VARCHAR2 (20),CLASSNAME VARCHAR2 (20)--Class ID);INSERT into STUDENT VALUES (1, ' Tom ', 1);INSERT into STUDENT VALUES (2, ' Jack ', 1);INSERT into

Shell string intercept--Get Oracle Group name

business background, when executing oracle file, need to authorize to the corresponding file, while we use chown-roracle:oraclegroup xxx, different server Oraclegroup The name is different, how to get it? method: First, we can obtain oraclegroups

Oracle Time Processing

One, the current timeUse the Sysdate function directly in SQL to represent the current time.So, using the current time, we can get the time information specified before and after the current time.1.1 Plus SubtractionSelectSysdate-1 fromdual;-- --

Oracle advanced query over (PARTITION by..)

In order to facilitate learning and testing, all of the examples are created under the Oracle's own user Scott.Note: The red Order by in the title indicates that you must bring an order by when using this method.Rank ()/dense_rank () over (partition

Oracle stored procedure execution can enter SQL statements and return result sets

1. Create a Test table:CREATE TABLE AAA(AA NVARCHAR2 (100),BB NVARCHAR2 (100),CC NVARCHAR2 (100),DD NVARCHAR2 (100))and import test data insert into AAA values (' 1 ', ' 1 ', ' 1 ', ' 1 ');2. Test feasibility:DECLAREV_cursor number;V_stat number;AA

oracle11g Database recovery After reinstalling the system (original Oracle installation directory is still in)

Install with previous version of the database, the installation directory selection is the same as before. Turn off all services from Oracle. Copy the database folder from the original Oracle_home directory to the current directory (it is a

Oracle 11G when exporting with exp, empty table cannot be exported to resolve

A new feature in 11G that does not allocate segment when the table has no data to save spaceWorkaround: 1, insert a row, and then rollback will produce segment.The method is to insert data into the empty table and then delete it, resulting in

Oracle IMP Import data appears ORA-12560

The error is as follows:D:\software\xfwebdb2015-05-11\autobackup>impImport:release 10.2.0.1.0-production on Wednesday May 13 19:36:10 2015Copyright (c) 1982, 2005, Oracle. All rights reserved.User name: ZFZBPassword:IMP-00058: Encountering ORACLE

Oracle internal connection and external connection

Oracle internal connection and external connection Inner join: We usually connect tables to display data with matched IDs. SELECT * FROM a, B WHERE a. aid = B. bid only retrieves matched data. Outer connections: Left connections and right

Modify tables, add columns, delete columns, and modify columns in oracle

Modify tables, add columns, delete columns, and modify columns in oracle1. Add ColumnsAlter table table_name ADD (column datatype [default expr] [, column datatype...]);For example:SQL> ALTER TABLE emp01 ADD eno NUMBER (4 ); 2. Modify column

Total Pages: 2147 1 .... 1223 1224 1225 1226 1227 .... 2147 Go to: GO

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.