Oracle查詢類預存程序調用樣本

預存程序:Code highlighting produced by Actipro CodeHighlighter

ORACLE–IF EXISTS函數

對於Oracle中沒有 if exists(...) 的文法,目前有許多種解決方案,這裡先分析常用的三種,推薦使用最後一種第一種是最常用的,判斷count(*)的值是否為零,如下declare  v_cnt number;begin  select count(*) into v_cnt from T_VIP where col=1;  if v_cnt = 0 then    dbms_output.put_line('無記錄');  end

Oracle Database中DBA常用的表和視圖

Technorati 標籤: oracledba_開頭   dba_users     資料庫使用者資訊   dba_segments  表段資訊   dba_extents    資料區資訊   dba_objects    資料庫物件資訊   dba_tablespaces   資料庫資料表空間資訊   dba_data_files    資料檔案設定資訊   dba_temp_files   臨時資料檔案資訊   dba_rollback_segs   復原段資訊  

使用UTL_FILE在oracle中讀寫文本資料

Technorati 標籤: oracle--以SYS使用者建立目錄dir_dump,檔案就儲存在這個目錄下SQL> create directory dir_dump as '/data/cmssdb';Directory created.--授權對應的操作帳號讀和寫的許可權,這裡是operatorSQL> grant read on directory dir_dump to operator;Grant succeeded.SQL> grant write on

Arcgis server:Connection To SDE ORACLE

• Top Print Reply Alert Moderator   SubjectConnection To SDE ORACLE AuthorMourad AbuSall DateJun 25, 2007 Messagei created this code to connect on geodatabase sde and this code not working i don't know why!!. what i do for this ?

[Oracle學習筆記] 撤銷資料表空間

撤銷表用於實現資料的回退,事務恢複等用途。撤銷資料表空間管理方式分兩種:1. 手工撤銷管理2. 自動撤銷管理由參數UNDO_MANAGEMENT確定,參數為AUTO,則為自動撤銷管理,為MANUAL則為手工撤銷管理。一般採用自動撤銷管理(預設值)。一、建立撤銷資料表空間與建立基本資料表空間類似,只是需要加上UNDO關鍵字樣本:SQL> create undo tablespace undotbs01  2  datafile 'f:\untotbs01.dbf' size 20M  3 

通過JDBC查詢資料庫外鍵對象-適用DB2, Oracle 和 MSSQL

通過JDBC訪問資料庫是,通過Connection對象的getMetaData()方法可以得到Table, Table Column, View, Index, Primary Key資料庫物件,但是它沒有提供外鍵對象,下面介紹如何訪問外鍵對象。程式片段如下:stmt = conn.createStatement();String strStmt = "";if(conn.getDbDBMS().equals(DBConstants.DB_TYPE_DB2)){strStmt ="SELECT

本機不安裝Oracle用戶端,使用PL/SQL Developer串連遠端資料庫

本文轉自:http://blog.csdn.net/caihaijiang/article/details/6083566 1、先到Oracle網站下載Instant Client :http://www.oracle.com/technology/global/cn/software/tech/oci/instantclient/index.html根據你的作業系統選擇不同的Instant

SQLServer和Oracle常用函數對比自藍色經典)

某種意義上也可以說是 sqlserver 和 mysql 的常用函數對比。數學函數  1.絕對值  S:select abs(-1) value  O:select abs(-1) value from dual   2.取整(大)  S:select ceiling(-1.001) value  O:select ceil(-1.001) value from dual   3.取整(小)  S:select floor(-1.001) value  O:select floor(-1.001

不安裝 oracle的客戶,就可以使用pl/sql訪問遠程oracle 資料庫的方法

 免安裝Oracle用戶端使用PL/SQL串連Oracle       大家都知道,用PL/SQL串連Oracle,是需要安裝Oracle用戶端軟體的。有沒要想過不安裝Oracle用戶端直接連接Oracle呢? 利用Oracle 提供的Instant Client Package      只需要在Oracle下載一個叫Instant Client

詳解 Oracle 10g 中 MERGE 功能的增強

Oracle9i引入了MERGE命令,你能夠在一個SQL語句中對一個表同時執行inserts和updates操作. MERGE命令從一個或多個資料來源中選擇行來updating或inserting到一個或多個表.在Oracle

Oracle—PL/SQL 基礎知識

什麼是PL/SQL•PL/SQL是由Oracle開發,專用於Oracle的一種程式設計語言•PL代表 ProceduralLanguage•SQL代表StructuredQuery Language•PL/SQL是Oracle資料庫對SQL語句的擴充,增加了程式設計語言的特點•PL/SQL 包含過程化語句和SQL語句•資料操作和查詢語句被包含在PL/SQL代碼的程式單元中(PL/SQL塊),經過邏輯判斷、迴圈等操作完成複雜的功能或者計算.PL/SQL

ASP.NET 中 .NET Data Provider for Oracle 的串連漏洞

原文見http://support.microsoft.com/default.aspx?scid=kb;zh-cn;330126我們的系統正有這個問題,在網上找不到微軟Hotfix,不知道哪位下載到微軟的修改程式,提供連結下載! 替代方法重新啟動 IIS 管理服務和所有 IIS 附屬服務和進程(例如:dllhost.exe 和 aspnet_wp.exe),可以釋放 Oracle 串連。 在 ASP.NET 應用程式中最經常出現此問題,因為 ASP.NET 能夠定期迴圈進程中的應用程式定義域。

[ASP.NET]解決ASP.NET安裝後無法訪問Oracle資料庫問題

問題安裝完ASP.NET,Oracle9i用戶端後,使用System.Data.OracleClient訪問Oracle資料庫時收到如下資訊System.Data.OracleClient requires Oracle client software version 8.1.7 or greater.原因Oracle 9i Release 2 用戶端在安裝到Windows的NTFS分區下時的安全認證設定不正確,引起原生Authenticated

oracle使用遊標進行迴圈資料插入

建表語句:beginexecute immediate ' drop table Customer';exception when others thennull;end; beginexecute immediate ' drop table OrderHistory';exception when others thennull;end;    -- Create Customer TableCREATE TABLE Customers(        Customer_Id NUMBER(

oracle中WMSYS.WM_CONCAT函數的版本差異

     昨天在測試的時候發現,開發人員寫的一段程式放在開發庫中是好的,但是放在測試庫中就會有問題。開發人員一直找不到問題的原因在哪裡。於是就花了點時間協助開發人員來找問題的根本原因。     通過一些技術手段,定位到問題是由一個SQL語句引起的。     SQL語句如下:WITH PXQ_TASK_TEMP AS (SELECT A.DISTRIBUTE_DATE, A.APP_NO, A.TASK_ID, A.TASK_NO,

Oracle 常用操作

//建立暫存資料表空間    create temporary tablespace test_temp     tempfile 'E:\oracle\product\10.2.0\oradata\testserver\test_temp01.dbf'     size 50m     autoextend on     next 50m maxsize 2048m    extent management local;//建立資料資料表空間    create tablespace

Oracle資料關聯查詢

來源:賽迪網    作者:Alizze關聯在Oracle資料查詢時會經常用到,靈活的應用關聯可以解決很多實際應用的問題.下面給出一些樣本: 建表 create table ab ( ab_id number(5), ab_name varchar2(30) ); create table bb ( bb_id number(5),

Oracle 建立使用者 修改使用者密碼 授權命令

create user [username] identified by [password] 建立新的使用者  grant 許可權1、許可權2...to 使用者  給建立使用者權限  ex:grant create session to [username] 此時只能串連到資料庫  grant connect,resource to [username] 此時許可權能滿足要求  alter user [username] identified by [password] 修改使用者密碼 

Oracle 函數replace和translate的比較

今天看了SQL COOKBOOK中的一個例子,其中看到了兩個函數Replace和Translate時產生了疑惑,感覺這兩個函數的作用是一樣的,書上面的例子也看的不是很明白,Google了一下,看了Oracle的官方解釋,終於徹底明白了。官方的解釋如下:REPLACEDescription of the illustration replace.gifPurposeREPLACE returns char with every occurrence of search_string

總頁數: 1509 1 .... 383 384 385 386 387 .... 1509 Go to: 前往

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.