Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

oracle Èý±íÁ´½Ó²éѯÎÊÌâ

table a£»             
userid               
  1
  2
  3
  5

table b£»
userid
  1
  2
  3
  5

table c£»
userid
  2
  6
  7

½á¹ûΪ£º
userid
  1
  2
  3
  4
  5
  6
  7

sql¸ÃÈçºÎд£¿
SQL code:

select
a.userid as x
from a a,b b,c c
where a.userid= b.userid(+) and b.userid = c.userid(+)
²¢²»ÄÜ´ïµ½ÎÒÏëÒªµÄ½á¹û


Äãa,b,c ±íÖж¼ ûÓÐ4°¡

select id
from a
unial
select id
from b
unail
select id
from c


ÒýÓÃ
select id
from a
unial
select id
from b
unail
select id
from c


µ¥´ÊдÁË´íÁË£¬Ó¦¸ÃÊÇ union

--ÓÃunion
select id from t1
union
select id from t2
union
select id from t3
order by id


select a.userid userid from a
union
select b.userid userid from b
union
select c.userid u


Ïà¹ØÎÊ´ð£º

OracleÀëÏß·ÃÎÊ---ÇóÖú - Oracle / »ù´¡ºÍ¹ÜÀí

´ó¼ÒºÃ,ÎÒÏÖÔÚ°Ñoracle·þÎñÆ÷ÉÏÃæµÄԭʼÎļþ,ÏÂÔØµ½±¾»úÁË.ÎÒÏëÔÚ±¾»ú·ÃÎÊÊý¾Ý¿âÔõôÉèÖð¡.ÊDz»ÊÇÀàËÆ¿ÉÒÔ½¨Á¢Ò»¸öʲôÐéÄâ·þÎñÆ÷À´ÊµÏÖ.Çë´ó¼Ò³ö³öÖ÷Òâ
ÒýÓÃ
    ´ó¼ÒºÃ,ÎÒÏÖÔÚ°Ñoracle·þÎñÆ÷ÉÏÃæ ......

javaÔõôÁ¬½ÓOracle£¬¼±°¡ - Java / JavaÏà¹Ø

private static final String URL = "jdbc:oracle:thin:@localhost:1521:orcl";
private static final String USERNAME = "sys";
private static final String PASSWORD = "s ......

oracle 9i ×î½ü·¢Ïֵǽ±¨´í - Oracle / »ù´¡ºÍ¹ÜÀí

ÓÃPL/SQL µÇ½ʱµ¯³ö±¨´í´°¿Ú£¬´íÎóÈçÏ£¡
  ORA-01034:ORACLE not available
  ORA-27101:shared memory realm does not exist
ÇëÎÊ£¬ÓÐûÓÐÈËÓöµ½ÕâÖÖÇé¿ö£¬Ôõô½â¾ö£¿Ð»Ð»£¡

1. Oracle sid ÕýÈ ......

Ò»¸öpl/sqlÎÊÌâ - Oracle / ¿ª·¢

ÎÒÊÇÔÚtoadÖÐÊäÈë϶Îsql
  declare
  TYPE test_rec IS record(
  code varchar(10),
  name varchar(30)
  );
  v_book test_rec;
    ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ