CREATE TABLE My_toys
(
ID VARCHAR2 (5),
name VARCHAR2,
Price Number
);
--Insert test data
INSERT into my_toys values (' G001 ', ' electric blanket ', 145);
INSERT into my_toys values (' G002 ', ' bikes ', 327);
INSERT into my_toys values (' G003 ',
Do not know who originally wrote the function, take over to record, may use later.
* * Where In_rowid is a row id,in_owner the account name for the database, In_table_name is the database table name, in_column a long type of table field name for
Paging Query format:
SELECT *
from (
select A.*, rownum RN to
(SELECT * FROM table_name) A
WHERE rownum = 21
The most inner query select * FROM table_name represents the original query statement without paging. RowNum = 21
Pseudo-column rownum in Oracle
Pseudo-column rownum, just like columns in a table, but not stored in a table. Pseudo-Columns can only be queried and cannot be added to the deletion operation. It generates a serialized number for each piece of data
1. Start time and end time of the week
Start time for the week, starting with Monday.
SELECT TRUNC (Date ' 2016-05-12 ', ' D ') + 1 from DUAL;
End time of the week, ending with Sunday
SELECT TRUNC (Date ' 2016-05-12 ', ' D ') + 7 from DUAL;
Definition:
A stored procedure (Stored Procedure) is a set of SQL statements that are compiled and stored in a database in order to complete a specific function. The user specifies the name of the stored procedure and gives the parameter, if the
In the project to find two days difference in the number of hours, with ceil the hour data is wrong, study the ceil (n) function, found that the function is more than equal to the number N of the smallest integer, which is very likely to have the
Official documents of the Http://tahiti.oracle.comoracleHttp://metalink.oracle.com/oracle's technical Support website. Need to purchase Oracle services to have an account, to log in, there are a large number of knowledge Base, a large number of
--View the use of table space files
SELECT
MAX (b.file_id) ID,
B.tablespace_name table Space,
B.file_name Physical file name,
b.bytes/1024/1024 size M,
(B.bytes-sum (NVL (a.bytes, 0)))/1024/1024 has used M,
SUBSTR (B.bytes-sum (NVL (a.bytes, 0))/
1 ORA-00955 2 ORA-12514 ORA-12504 3 command line unable to log in
1 ORA-00955
This error occurred while building the table, the name is already used by the existing object (name is already used by a existing object), let's analyze it.First, you must
First, create the directory folder for the exported data
Create or replace directory Oradata as ' E:\data ';
Note:
(1) The Data folder needs to be created by itself under this disk.
(2) If the prompt permission is insufficient, need to authorize
querying the table space in the current database whether to expand automatically
Select tablespace_name,file_name,autoextensible from Dba_data_files;To automatically expand the table space by modifying the data file for the tablespace, and limit
First, the environment needs the software:1, operating system: RedHat Linux 6.22. Database: Oracle8.1.63, Java Operating environment: J2sdk-1_3_0_02-linux-rpm.bin4, Tomcat:jakarta-tomcat-3.1.1.tarSecond, the installation before the
BIEE is Oracle's Business Intelligence Enterprise Enhancements (EE) is a comprehensive enterprise BI product that delivers complete BI functionality, including interactive dashboards, fully ad-hoc proactive intelligence and alerting, enterprise and
Redo (Redo) log features: Data recovery
4.2 Redo Log Features:
1 record database Changes (DML, DDL)
2) for recover of data blocks
3 Manage Redo file in group mode, at least two groups of redo, recycle
4 and data files on different disks, need to
2.TRUNC (for number)
The TRUNC function returns the processed value, which works very much like the round function, except that the function does not round the specified decimal number before or after the appropriate rounding selection.
Its specific
18, NCLOBYou can use character sets that are defined by the database international character set to store character-based data that is only Unicode type. You can store up to 4GB of data, which is larger than the maximum amount of data that can be
1. What's the difference between after and before in a trigger in Oracle?One is triggered before the record operation, and one is triggered after the record operation.
2. What occasions are used separatelyFor example, the definition between the
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