oracle³£¼ûÓï¾ä(תÔØ)
--==================================== Ò».sqlÓï¾ä·½Ãæ ====================================================
--========================================================================================================
1.Ôö¼ÓÖ÷¼ü
alter table TABLE_NAME add constraint KEY_NAME primary key (TABLE_COLUMN);
Ö¸¶¨±í¿Õ¼ä
alter table TABLE_NAME add constraint KEY_NAME primary key (TABLE_COLUMN) using index tablespace TABLE_SPACE_NAME;
2.Ôö¼ÓÍâ¼ü
alter table TABLE_NAME add constraint FK_NAME foreign key (TABLE_COLUMN) references KEY_TABLE_NAME;
3.ʹÖ÷¼ü»òÍâ¼üʧЧ¡¢ÉúЧ
alter table TABLE_NAME disable(enable) constraint KEY_NAME;
4¡¢²é¿´¸÷ÖÖÔ¼Êø
select constraint_name,table_name,constraint_type,status from user_constraints;
select constraint_name, constraint_type,search_condition, r_constraint_name from user_constraints where table_name = upper('&table_name')
select c.constraint_name,c.constraint_type,cc.column_name
from user_constraints c,user_cons_columns cc
where c.owner = upper('&table_owner') and c.table_name = upper('&table_name')
and c.owner = cc.owner and c.constraint_name = cc.constraint_name
order by cc.position;
5¡¢É¾³ýÖ÷¼ü»òÍâ¼ü
alter table TABLE_NAME drop constraint KEY_NAME;
6¡¢½¨Íâ¼ü
µ¥×Ö¶Îʱ£ºcreate table ±íÃû (col1 char(8),
cno char(4) REFERENCE course);
¶à¸ö×Ö¶Îʱ,ÔÚ×îºó¼ÓÉÏ Foreign Key (×Ö¶ÎÃû) REFERENCE ±íÃû(×Ö¶Î)
Á¬´øɾ³ýÑ¡Ïî (on delete cascade
&nbs
Ïà¹ØÎĵµ£º
²é¿´sessionµÈ´ýʼþ£º
select sid,event from v$session_wait where event not like 'rdbms%' and event not like 'SQL*Net message%';
°´pid²é¿´ÕýÔÚÖ´ÐеijÌÐò£º
select sid,program from v$session b where paddr in (selec ......
¹ú¶¼ºÅÂëÊý¾Ý¿âÉè¼Æ˵Ã÷
V1
Îĵµ±ä¸ü¼Ç¼
ÐòºÅ
±ä¸üÄÚÈÝ˵Ã÷
°æ±¾ºÅ
°æ±¾ÈÕÆÚ
Ö´±ÊÈË
1
³õ¸å
V ......
Mysql·½Ê½£º
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;
public class MysqlDB {
private String strClass = "com.mysql.jdbc.Driver";
private String strDriver = "jdbc:mysql://localhost: ......
Ê×ÏÈÐèÒªµÄÈí¼þÓУº
1¡¢
linux_11gR1_database.zip
//¿ÉÔÚOracleµÄ
¹Ù·½ÍøÕ¾
ÏÂÔصõ½£¬ÓÐ1.71GB¹»´ó°É¡£
2¡¢ ±ðÍüÁË×¼±¸Ò»·ÝOracleµÄ¹Ù·½°ïÖúÎĵµ
£¬ÊÇ×îȨÍþµÄ¡£
3¡¢
CentOS-5.2-i386-bin-DVD.iso
//¿ÉÔÚCentOS
¹Ù·½ÍøÕ¾
ÏÂÔصõ½£¬Ó ......
ÓÃOracle²éѯÓï¾äÓ¦ÓþÑé×ܽá
¡¡ÒÔϵÄÎÄÕÂÖ÷ÒªÊǽéÉÜOracle²éѯÓï¾äµÄʵ¼ÊÓ¦ÓõľÑé×ܽᣬÄãÈç¹û¶ÔOracle²éѯÓï¾äµÄʵ¼ÊÓ¦ÓøÐÐËȤµÄ»°Äã¾Í¿ÉÒÔµã»÷ÒÔϵÄÎÄÕ½øÐйۿ´ÁË¡£ Ï£Íû»á¸øÄã´øÀ´Ò»Ð©°ïÖúÔÚ´Ë·½Ãæ¡£
¡¡¡¡1. select * from table_name where rownum>begin and rownum< end
¡¡¡¡2.sql = "select * fr ......