ÔÚoracleÀûÓÃÓαêÈ¡Êý¾Ý¿âµÄ½á¹û¼¯Ó¦ÓÃʵÀý£º
SQL> create table test2(s1 varchar(10),s2 varchar2(10));
±íÒÑ´´½¨¡£
SQL> insert into test2 values('11','111');
ÒÑ´´½¨ 1 ÐС£
SQL> insert into test2 values('22','222');
ÒÑ´´½¨ 1 ÐС£
SQL> CREATE OR REPLACE PACKAGE test222 AS
2 TYPE t_cursor IS REF CURSOR;
3 procedure p_test1( p_dd in out t_cursor);
4 end;
5 /
³ÌÐò°üÒÑ´´½¨¡£
SQL> CREATE OR REPLACE package body test222 AS
2 procedure p_test1(
3 p_dd in out t_cursor)
4 is
5 begin
6 open p_dd for select * from test2;
7 end;
8 end;
9 /
³ÌÐò°üÖ÷ÌåÒÑ´´½¨¡£
SQL> var ss refcursor
SQL> exec test222.p_test1(:ss);
PL/SQL ¹ý³ÌÒѳɹ¦Íê³É¡£
SQL> print ss
S1 S2
---------- ----------
11 111
22 222
SQL>
Ïà¹ØÎĵµ£º
extent--×îС¿Õ¼ä·ÖÅ䵥λ --tablespace management
block --×îСi/oµ¥Î» --segment management
create tablespace james
datafile '/export/home/oracle/oradata/james.dbf'
size 100M ¡¡¡¡¡¡¡¡¡¡¡¡--³õʼµÄÎļþ´óС¡¡
autoextend On¡¡¡¡¡¡¡¡ --×Ô¶¯Ôö³¤
next 10M¡ ......
½ñÌì¿Í»§µÄÒ»Ì×RAC»·¾³³öÏÖÎÊÌâ
Ë«½ÚµãRAC»·¾³ÖУ¬Ò»¸ö½ÚµãÒòÎªËø¾ºÕù¶ø¹ÒÆð£¬shutdownÖ®ºóÎÞ·¨Æô¶¯¡£
¹ÊÕϳöÏÖʱÎÒÕýÔÚ·ÉÏ£¬´Ò´Ò»Øµ½¼ÒÖУ¬´¦Àí¹ÊÕÏ¡£
½â¾öÖ®ºó²éÕÒ¹ÊÕÏÔÒò¡£
¼ì²éµ±Ê±µÄAWRÐÅÏ¢·¢ÏÖTop 5 Timed EventsÏÔʾÈçÏÂÐÅÏ¢£º
Top 5 Timed Events &nb ......
Just a few days ago a got to two Oracle DBAs discussing why the have so much “PX Deq Credit : send blkd” on a system. And if that is causing their performance problems.
The are some blog on the internet claiming it has to do with qc distribution and what ever.
But in many cases, especi ......
oracle wait event:cursor: pin S wait on X
cursor: pin S wait on XµÈ´ýʼþµÄ´¦Àí¹ý³Ì
http://database.ctocio.com.cn/tips/114/8263614_1.shtml
cursor: pin S wait on XµÈ´ý£¡
http://www.itpub.net/viewthread.php?tid=1003340
½â¾öcursor: pin S wait on X ÓÐʲôºÃ°ì·¨:
http://www.itpub.net/thread-1163543 ......
1¡¢´´½¨´æ´¢¹ý³Ì
create or replace procedure test(var_name_1 in type,var_name_2 out type) as
--ÉùÃ÷±äÁ¿(±äÁ¿Ãû ±äÁ¿ÀàÐÍ)
begin
--´æ´¢¹ý³ÌµÄÖ´ÐÐÌå
end test;
´òÓ¡³öÊäÈëµÄʱ¼äÐÅÏ¢
E.g:
create or replace procedure test(workDate in Date) is
begin
dbms_output.putline('The input date i ......