2008/03/07Skate
A variable can be defined in a cursor, and the following is an example of the procedure of my Update column order
Create or replacePROCEDURE TEST as--v_id varchar2;--V_num number;--v_x number;I number (10,0): = 1;v_id VARCHAR2 (32);V_
For example, the following error occurred, how to solve it? SELECT Job,what,log_user,to_char (last_date, ' yyyy-mm-dd HH24:MI:SS '), To_char (Next_date, ' Yyyy-mm-dd HH24:MI:SS '), Interval,failures,broken from User_jobs; JOB WHAT log_user to_char
Oracle Related dictionaries:
User_source user's stored procedure, function's source code dictionaryDba_source The source code Dictionary of the stored procedures and functions for all users of the entire systemAll_source the current user can use
Transferred from http://layznet.javaeye.com/blog/592873
When you write a stored procedure before, the exception handling is:...EXCEPTIONWhen others THENROLLBACK;End ...This type of writing when the stored procedure throws an exception, we do not
The first method: Log in with the system account like Sys as SYSDBA 1, view the database lock, diagnose the source and type of the lock: select Object_id,session_id,locked_mode from V$locked_object; or use the following command: Select
1 in the PowerDesigner table, and the various associations between the tables, when finished, select the menu item in the "Database" under the "Generate Database", find a path, save as a SQL statement.
2 in Pl/sql, tool "Import table, select the
Simple and practical, not much nonsense said:
[SQL] view plain copy Select Substr (' A, ', 2,1) from dual;substr (' character to intercept ', length of character, character length-1)
Extended:
[SQL] view plain copy Select substr
CREATE OR REPLACE TYPE ty_object as OBJECT (Col_name VARCHAR2);
/
CREATE OR REPLACE TYPE ty_table as TABLE of Ty_object;
/
CREATE OR REPLACE FUNCTION str2table (v_str in VARCHAR2,
v_delimiter in VARCHAR2)
--
1
SELECT * FROM
(
SELECT segment_name, SUM (BYTES)/1024/1024 M
From Dba_segments
WHERE OWNER = user
GROUP by Segment_name
ORDER BY 2 DESC
)
2 The second method
SELECT Partition_name, High_value, High_value_length, Tablespace_name,
Pct_free, pct_used,
Oracle Bulk Import test data One, test WinDOS methodDeclareMAXRECORDS constant int:=1000;I int: = 1;BeginFor I in 1..maxrecords loopINSERT INTO Test2(ID, name)Values(Test2_seq.nextval, To_char (' 9999 ' +i));End Loop;Dbms_output.put_line ('
A long time ago, look back.
1.os:gentoo-linux-2.6.23-rc5
Oracle:oracle Database 10g Release 2 (10.2.0.1.0) for Linux x86
Download Address:
http://www.oracle.com/technology/software/products/database/oracle10g/index.html (Size 668,734,007 bytes)
Oracle in%rowtype:
%rowtype: Indicates that the type is a row data type, stored as a row of data, a row with many columns, equivalent to a row of data in a table, or a row of data in a cursor.
The%rowtype effect is that when querying the entire
SUBSTRING, this function is used to find a string of strings, the function of the use of high frequency.
Sample string: "2011-11-17"
The function to ask for a string in Oracle is: SUBSTR
The syntax for the SUBSTR function is:
substr (String,
Time is not to be mistreated.
Install the Oracle 11g, need to install the RPM dependency pack, according to the Oracle official website, the need to install the RPM package is certain, but these dependencies may depend on different systems depending
First look at the Oracle database encoding
Sql> SELECT * from nls_database_parameters where parameter = ' nls_characterset ';
PARAMETER
--------------------
VALUE
--------------------
Nls_characterset
Al32utf8
This is derived from props$,
Oracle detects a few previous records based on a record in the table
My watch is: Info_m1_tran
Preferred to first navigate to this record in the table rownum, I sorted according to data_time ASC then the rownum value of the existing records will not
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