1. select * from s_hrdata2. create Sequence: create sequence s_hrdata_SEQUENCE start with 1 increment by 13. CREATE Trigger: create or replace trigger s_hrdata_trgger before insert or update of id on s_hrdata for each row begin select
SQL code for viewing the usage of each ORACLE tablespace -- select tablespace_name, sum (bytes)/1024/1024 from dba_data_files group by tablespace_name; -- select tablespace_name, sum (bytes) /1024/1024 from dba_free_space -www.2cto.com-group by
Some tips of plsql developer 1. After logon, My Objects is automatically selected by default. By default, after PLSQL Developer logs on, All objects will be selected in Brower. If the user you log on to is dba, to expand the tables directory, it
In oracle, you can use the connect by clause to implement recursive queries. The basic syntax is: select... from where start with connect by order siblings by ; : filter condition used to filter all returned records. (The Association condition
In PL/SQL, % ROWTYPE can be used as the row TYPE of a table, and % TYPE can be used as a field as the data TYPE, but several fields to be specified must be used as a data TYPE, you can use PL/SQL records. Definition Syntax of PL/SQL records: SQL
MERGE is a composite statement used to implement INSERT, UPDATE, and DELETE operations at a time. Syntax: merge into table/view using (TABLE/VIEW/SUBQUERY) ON (condition) [when metched then update set column = expr/DEFAULT [WHERE condition] www.2cto.
1. system permission management 1.1 three default users: oracle 9i sys change_on_install [as sysdba] -- sqlplus/as sysdba system manager www.2cto.com scott triger oracle 10 Gb or above sys. [as sysdba] set during system installation. scott triger is
The differences between drop, delete, and truncate in oracle are described as follows:1. Both delete and truncate can delete the data in the table. However, compared with drop, the former only deletes the data and does not change the table structure.
Fault symptom: ORA-01078: failure in processing system parametersLRM-00109: cocould not open parameter file '/u01/app/oracle/product/10.2.0/db_1/dbs/initorcl10g. ora principle: in oracle9i and oracle10g, the database starts with spfile by default.
Three steps nomount, mount, and open for Oracle Database Startup: conn sys/sys as sysdbaShutdown abort; Startup nomount; select instance_name, status from v $ instance; www.2cto.com: select value from v $ spparameter where name = 'control _ files ';
Solution: create table t_20120512_a (id varchar2 (6) primary key, cost number (3), www.2cto.com p2 number (3), p3 number (3 )) /create table t_20120512_ B (id varchar2 (6) primary key, name varchar2 (50), B varchar2 (100)/insert into t_20120512_a
Create a table, prompting ORA-00959: tablespace 'mc _ data' does not exist solution first, first confirm the current user's tablespace. Select username, default_tablespace, temporary_tablespace from dba_users where username = 'mcmidyl'; www.2cto.com
Oracle Date and Time Range Query SQL code/* Date and Time Range Query */---------- create Date and Time Test table ‑ www.2cto.com create table testdatetime (ID integer not null primary KEY, createdate CHAR (10) NULL, startdate date null, enddate
The relationship between Oracle sessions and processes is sessions = 1.1 * processes + 5 www.2cto.com ----- experiment part ---- Microsoft Windows [version 5.2.3790] (C) Copyright 1985-2003 Microsoft Corp. c: \ Documents ents and Settings \
Oracle External combined command oracle External combined command: To understand (+), the most important thing is that (+) is always placed on the side where information is scarce, and records on this side are displayed as null values. Example:
ORA-14048: partition maintenance operation cannot be combined with other operations today fannairu students imported database error, prompt: IMP-00017: Due to ORACLE error 14048, the following statement failed: "alter index" SYS_C009967 "unusable
Oracle uses a stored procedure with input and output parameters. It is still a bit troublesome to use the stored procedure. If you are not careful about the parameter errors, you are advised to use them less if you can use them less. Here I want to
Solve the Problem of ora-12154 recently the project uses oralce 10g as the database, haven't touched for a long time, but vaguely remember that there is such a tool pl/SQL can be very convenient to operate the database. After pl/SQL is installed on
The ORACLE line to multi-row problem/** the core solution is to generate a column from 1 to 10, as A "secondary column" **/select level l FROM dual connect by level /** Create a test TABLE T1, that is, table a mentioned by the landlord **/create
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.