標籤:1.集合 --集合操作: 並集、交集、差。 select deptno,job,sum(sal) from emp group by deptno,job union select deptno,to_char(null),sum(sal) from emp group by deptno union select to_number(null),to_char(null),sum(sal) from emp; select
標籤:--sde使用者登陸執行以下語句grant insert, update, delete on sde.table_registry to PUBLIC;grant insert, update, delete on sde.column_registry to PUBLIC;grant insert, update, delete on sde.geometry_columns to PUBLIC;grant insert, update, delete on sde.layers
標籤:文法select ... from 表where 過濾條件start with 查詢結果根結點的限定條件connect by 串連條件; 例子create table test(id number,parent_id number,name varchar2(100)); 假設根節點id為1全部資料(正向遞迴)select * from test start with id=1 connect by prior id
標籤:Oracle10g中引入了閃回技術,但這並不意味著所有的表都能閃回成功,當沒有足夠的磁碟空間,Oracle將使用資源回收筒中的磁碟空間,而且位元影像串連索引和參考完整性約束也不受資源回收筒的保護。recyclebin參數的設定show parameter bin --展示是否使用了閃回技術,預設是使用閃回技術的alter session set recyclebin=off; --在session層級修改alter system set recyclebin=off
標籤:作用:1.預存程序只在創造時進行編譯,普通sql則會每執行一次就運行一次,所以使用預存程序可以提高資料庫執行速度。2.當對資料庫進行複雜操作時(如對多個表進行Update、Insert、Query、Delete時),可將此複雜操作用預存程序封裝起來與資料庫提供的交易處理結合一起使用。3.預存程序可以重複使用,減少開發工作量4.安全性高,可以指定某些使用者才具有預存程序使用權。 --1不帶參數的過程CREATE OR REPLACE PROCEDURE
標籤:在工作中遇到的情況簡單說下:--首先要賦予使用者建立dblink的許可權。grant resource to ods_nwsc;grant create database link to ods_nwsc; --在賦予許可權的使用者下面建立dblink的代碼。CREATE database link link_nwscCONNECT TO lcam_sc IDENTIFIED BY lcam_SC_201504USING ‘(DESCRIPTION = (ADDRESS_LIST =