Exists(The result set returned by SQL is true)NotExists(The result set is true if SQL does not return)
As follows:TableTable B
The relationship between table A and table B is one-to-many. A. ID=>B. Aid
SelectA. IDFromAWhere Exists(SelectA.
Create Or Replace Package pagequery_pack Is -- Author: Administrator -- Created: 15:47:30 -- Purpose: FEn ye Cha Xun -- Public type declarations Type cur Is Ref Cursor ; -- Public Function and procedure declarations
■ View the server parameter file used SQL> show parameter spfile; ■ Use server parameter files to create text parameter filesSQL> Create pfile from spfile;SQL> Create pfile [= '...'] From spfile [= '...']; ■ create a server parameter file SQL>
Key factors affecting Oracle Efficiency
Original http://hi.baidu.com/odbcconnection/item/f4a56cbf1c8bea422bebe32f
1: select the most efficient table name sequence (only valid in the rule-based Optimizer) OracleThe parser processes the
This stored procedure is as complicated and strange as my mind...
First, we will introduce the structure of the hr_department table.
The main columns can be classified into the following items:
SelectT1.cpny _ idAsCompany_id, t1.deptid dep_id,
1. Create a user information table
Create Table user_info (Id varchar2 (4 ),Name varchar2 (20 ),PWD varchar2 (20 ),Address varchar2 (30));2. Create a stored procedure named addnewuser using SQL statements.
Create or replace procedure addnewuser
ReferenceArticleHTTP://Blog.itpub.net/Post/33454/395121HTTP://Www. ADP-GmbH. ch/Blog/2005/May/27. Html
Define a plan (executed every day)
Call dbms_scheduler.create_schedule ('Back_up_indonesiaprod2', Sysdate,'Freq = daily', To_date ('2013-03-
Thank you for your mission.
ReferencesHttp://wenku.baidu.com/view/39b2e437b90d6c85ec3ac6af.htmlHttp://wenku.baidu.com/view/39b2e437b90d6c85ec3ac6af.html
Local Operation Records
D: \ oraclexe \ app \ oracle \ product \ 10.2.0 \ Server \ bin>
9: replace in with exists.Important
Case: Search for the dept_1 Department employee name
9. 1 SQL statement
-- Subquery Select Pname From T_person Where Deptid In ( Select Deptid From T_department Where Deptname Like ' Dept_1 ' ); --
Field name
Hr_employee.activity
Original Field Type
Number (1)
New Field Type
Varchar2 (10)
Modify Scheme
/* modify the original field name */ alter table hr_employee rename column activity to activity_temp; /* Add a field with
Step 1:
Windows OS 7 flagship Edition)
Create a tablespace and allocate it to a user.
1. Install the Oracle service
1. Installation File
E: \ f \ development tool \ dB \ oracle \ oraclexe.exe
2 installation path
D: \ oraclexe
3
How can I execute SQL statements in PLSQL stored procedures?
Use dynamic SQL Execution:Execute immediate
Table Information
Select * FromEmp_temp;
Stored Procedure
Create Or Replace Procedure F_delete_rows (
I. Overview Four data types are defined in oracle8: Scalar, composite, reference, and lob. The following describes their features. Ii. scalar) The valid scalar type is the same as the type used by the database columns. In addition, it has some
Sometimes we may not know the password of a user, but we need to perform some operations with this user, and we cannot modify the password of this user. At this time, we can use some tips, to complete the operation.
The procedure is as follows:
SQL *
Eg: Related parsing: Table t_pi_part field ID code namevalue 1 222 avalue 2 222 bvalue 3 333 C add a row mark to the part code with the same code and sort select P by ID. *, row_number () over (partition by P. code Order order by. id DESC) as
In the Oracle-MSSQL Convert tips (1) I already mentioned several tips that used very often.
Today's project contains too much views, stored procedures and trigger and the lines of these code are big.
So I try to find some tools to validate the
--Full import and export of databases in Oracle: cmd command line mode thanks to clown _ shipping time: Source: tutorial
Importing and exporting Oracle Data imp/exp is equivalent to restoring and backing up ORACLE data. The exp command can export
1. When multiple tables are combined, an error "Character Set mismatch" is returned when the nvarchar2 type is encountered"
A: Add to_char (variable or field of nvarchar) to the place where nvarchar is used)
2. When multiple tables are union, 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