Oracle²åÈëÊý¾Ýʱ»ñÈ¡×ÔÔöID
×ÔÔö×ֶΣº
±íatable(id,a) idÐèÒª×ÔÔö Ê×ÏȽ¨Á¢Ò»¸öÐòÁУº
create sequence seq_atable minvalue 1 maxvalue 999999999999999999 start with 1 increment by 1 nocache
ÓжþÖÖ·½Ê½Ê¹ÓÃ×ÔÔö×ֶΣº
ʹÓÃÐòÁÐ+´¥·¢Æ÷ʵÏÖ×ÔÔö£¬²åÈëÓï¾ä²»ÐèÒª¹Ü×ÔÔö×Ö¶Î
È磺create or replace trigger trg_atable before insert on atable for each row begin select seq_atable.nextval into :new.id from dual; end;
²åÈëÊý¾Ý£ºinsert into atable(a) values('test');
×¢£ºÎÒ´´½¨ÁËsequence ºÍtrigger £º£¬Ö®ºóÔÚprocedureÖвåÈëÊý¾Ý£¬²åÈëµÄʱºòûÓйÜID×ֶΣ¬ÔÚÓ¦ÓÃÖУ¬Ê¹ÓÃÁËhibernate£¬ËäÈ»hibernateÔÚÔö¼Ó¼Ç¼µÄʱºòÒ²»á´¦ÀíID£¬µ«ÊÇÌí¼Ó¼Ç¼֮ºó£¬²éѯ¼Ç¼·¢ÏÖ£¬ID»¹ÊǸù¾ÝÐòÁкʹ¥·¢Æ÷µÄ¹æÔòÉèÖõÄ
½öʹÓÃÐòÁУ¬ÐèÒªÔÚ²åÈëÊý¾Ýʱ£¬×ÔÔö×ֶβåÈëÐòÁÐÏÂÒ»¸öÖµ
È磺insert into atable(id,a) values(seq_atable.nextval,'test');
Èý¡¢·µ»Ø¸Õ²åÈë¼Ç¼µÄ×ÔÔö×Ö¶ÎÖµ
ÈçÉÏÃæµÄÀý×Ó£¬ÎÒÃDzåÈëÒ»Ìõ¼Ç¼ºó£¬ÎÒÏëÂíÉÏ·µ»Ø¸Õ²åÈëµÄ¼Ç¼µÄIDºÅ£¬ÎÒ¸ÃÔõô´¦ÀíÄØ£¿
Ê×ÏÈÒª½â¾ö×ÔÔö×ֶεÄÎÊÌ⣬ÉÏÃæµÄ¶þÖÖ·½·¨ÄÄÖÖ¸üÊʺÏÕâÖÖÓ÷¨ÄØ£¿ ½¨ÒéʹÓõڶþÖÖ×ÔÔöÐòÁÐ,·ñÔò´¦ÀíÆðÕâ¸öÎÊÌâÀ´±È½ÏÂé·³¡£
ʹÓÃ×ÔÔö×ֶεĵڶþÖÖ·½·¨£¬ÔÚ²åÈëÒ»Ìõ¼Ç¼ºóÂíÉÏÖ´ÐÐÒ»ÏÂÏÂÃæµÄÓï¾ä¼´·µ»Øµ±Ç°²åÈëÊý¾ÝµÄID¡£
$query="select seq_atable.currval from dual";
seq_atable.currval µÄÖµÖ»ÓÐÔÚͬһ´Î»á»°ÖУ¬·¢Éúseq_atable.nextvalºóÓÐЧ£º£© ËùÒÔ²»»á´æÔÚÈ¡´íÖµµÄÎÊÌâ¡£
Ïà¹ØÎĵµ£º
£¨1£©²éѯC01¿Î³Ì³É¼¨²»ÎªNullµÄѧÉúµÄÐÕÃûºÍ³É¼¨¡£
·ÖÎö£ºÒòΪÉæ¼°µ½¿Î³Ì³É¼¨ºÍѧÉúÐÕÃû£¬ÐèÒª¶Ôstudent±íºÍsc±í½øÐÐÁ¬½Ó¡£
´úÂ룺
select sname,grade from student,sc where student.sno=sc.sno and c ......
ÔÚÐéÄâ»úRed Hat Enterprise Linux 4 update 4Öа²×°oracle 10.2.0.1
1)²é¿´ÏµÍ³ÄÚ´æ
[root@linux4 ~]# grep MemTotal /proc/meminfo
2)²é¿´½»»»Çø´óС
[root@linux4 ~]# grep SwapTotal /proc/meminfo
3)
²é¿´/tmpĿ¼´óС
[root@linux4 ~]# df -m /tmp
4)²é¿´²Ù×÷ϵͳ°æ±¾
[root@linux4 ~]# cat /etc/issue
5)¼ ......
µ¼³öÊý¾Ý¿â£ºexp Óû§Ãû/ÃÜÂë@Êý¾Ý¿âÃû file=ÅÌ·û£º/Îļþ¼Ð/ÎļþÃû.bmp owner=Óû§ »ò exp Óû§Ãû/ÃÜÂë@Êý¾Ý¿âÃû file=ÅÌ·û£º/Îļþ¼Ð/ÎļþÃû.bmp full=y
µ¼ÈëÊý¾Ý¿â£ºimp Óû§Ãû/ÃÜÂë@Êý¾Ý¿âÃû file=µ¼³öµÄÎļþ full=y ......
Ò»¡¢
´ò¿ª¿ØÖÆ̨£º
´ò¿ª http://localhost
:7001/console
£¬Æô¶¯¹ÜÀí¿ØÖÆ̨¡£ÊäÈë¹ÜÀíÔ±Óû§ÃûºÍÃÜÂ루ĬÈÏ£ºweblogic/weblogic£©¡£
¶þ¡¢´´½¨
JDBCÊý¾ÝÔ´£º
1¡¢
µ¥»÷“Ëø¶¨²¢±à¼
”°´Å¥£»
2¡¢
ÔÚ“Óò½á¹¹
”Ê÷ÖУ¬Õ¹¿ª“·þ
Îñ”>“JDBC”
£¬È»ºóÑ¡Ôñ“Ê ......