Time of Update: 2018-07-23
J2EE開發各類資源下載清單, 史上最全IT資源,點擊進入。 1.普通SID方式 jdbc:oracle:thin:username/password@x.x.x.1:1521:SID2.普通ServerName方式 jdbc:oracle:thin:username/password@//x.x.x.1:1522/ABCD 3.RAC方式jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS_LIST=
Time of Update: 2018-07-23
導讀: MyEclipse Database Explorer建立oracle資料庫連接的時候,不管用哪個oracle jdbc驅動包(classes12.jar,ojdbc14.jar),都會報出下面的錯誤. java.sql.SQLException: ORA-00604: error occurred at recursive SQL level 1 ORA-12705: invalid or unknown NLS parameter value
Time of Update: 2018-07-23
對於oracle資料庫只有物理備份 和邏輯備份 物理備份:是將實際組成資料庫的作業系統檔案從一處拷貝到另一處的備份過程,通常是從磁碟到磁帶。 邏輯備份:是利用SQL語言從資料庫中抽取資料並存於二進位檔案的過程。 第一類為物理備份,該方法實現資料庫的完整恢複,但資料庫必須運行在歸擋模式下(業務資料庫在非歸擋模式下運行),且需要極大的外部存放裝置,例如磁帶
Time of Update: 2018-07-23
最近在做一個使用Spring+Hibernat的小項目,我也是剛剛學習,邊學邊做吧。經常遇到一些小問題,這次在MyEclipse中使用DB Browser無法串連到Oracle資料庫。 下面是我的出問題的原圖: 1.建立串連到Oracle,如圖1: 2.串連到Oracle,如圖2: 3.出錯了,如圖3:
Time of Update: 2018-07-23
一、在Linux下啟動Oracle 登入到CentOS,切換到oracle使用者權限 # su – oracle 接著輸入: $ sqlplus "/as sysdba" 原本的畫面會變為 SQL> 接著請輸入 SQL> startup 就可以正常的啟動資料庫了。 另外停止資料庫的指令如下:
Time of Update: 2018-07-23
--create sales tableCREATE TABLE sales(trans_date DATE, cust_id INT, sales_amount NUMBER); --insert sale rowsINSERT /*+ APPEND */INTO SALES SELECT TRUNC(SYSDATE, 'year') + MOD(ROWNUM, 366) TRANS_DATE,
Time of Update: 2018-07-23
instr(string,substring[,start[,occurence]]) 第三個參數,開始搜尋位置 第四個參數,搜尋的子串第幾次出現。 如:select instr(url,'X',1,2),url from table_name where select_condition
Time of Update: 2018-07-23
Oracle資料庫的四種啟動方式 1、startup nomount 非安裝啟動:這種方式啟動下可執行:重建控制檔案、重建資料庫、啟動instance,即啟動SGA和後台進程,這種啟動只需要init.ora檔案。 2、startup mount dbname 安裝啟動:這種方式啟動下可執行:資料庫日誌歸檔、資料庫恢複、重新命名一些資料庫檔案 ,如:系統資料表空間或記錄檔。執行“nomount”,然後開啟控制檔案 3、startup open
Time of Update: 2018-07-23
在Solaris10中為Oracle配置系統資源 文/呼必斯哈拉圖 摘要: 在 Solaris10 這個版本中的系統資源組態管理較之前的版本有較大的變化。諸如 Oracle 等,
Time of Update: 2018-07-23
Oracle查詢中包含特殊的字元分別為%,_,&,想查詢某資料表某欄位的包含這種特殊字元的內容,需要使用逸出字元,或者拼接字串的方法。 0.原資料 select * from t_web_groups where groupid=10088; --------------------------------------------------------------------------- GROUPID GROUPNAME &
Time of Update: 2018-07-23
在Oracle8I的版本中,Oracle推出了一種全新的資料表空間管理方式:本地化管理的資料表空間。 所謂本地化管理,就是指Oracle不再利用資料字典表來記錄Oracle資料表空間裡面的區的使用狀況,而是在每個資料表空間的資料檔案的頭部加入了一個位元影像區,在其中記錄每個區的使用狀況。每當一個區被使用,或者被釋放以供重新使用時,Oracle都會更新資料檔案頭部的這個記錄,反映這個變化。 本地化管理的資料表空間的建立過程:
Time of Update: 2018-07-23
select SYS_CONTEXT('USERENV','TERMINAL') terminal, SYS_CONTEXT('USERENV','LANGUAGE') language, SYS_CONTEXT('USERENV','SESSIONID') sessionid, SYS_CONTEXT('USERENV','INSTANCE') instance,
Time of Update: 2018-07-23
1.先將上面4個包放到lib檔案夾下面 2.配置XML,放在SRC目錄下 <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE generatorConfiguration PUBLIC "-//mybatis.org//DTD MyBatis Generator Configuration 1.0//EN"
Time of Update: 2018-07-23
create or replace function row_split(var_str in string, var_split In String) return t_ret_table PIPELINED as var_tmp varchar2(4000); var_element varchar2(4000); n_length Number := length(var_split);begin var_tmp := var_str; while instr(
Time of Update: 2018-07-23
1、在powerDesinger中設計表 (1)下載powerDesinger後,右鍵NEW-->Physical data model預設名為:PhysicalDiagram_1, 右鍵NEW-->TABLE,開始表的設計 (2)配置odbc資料來源 在你的電腦的 控制台\系統和安全\管理工具(我的是W7的系統) 中配置ODBC資料來源,
Time of Update: 2018-07-23
select t.table_name,t.num_rows from user_tables t 若以上SQL尋找不到,執行如下指令碼即可:
Time of Update: 2018-07-23
create or replace function test111(itemNumber in varchar2) return SYS_REFCURSOR is return_cursor SYS_REFCURSOR; begin OPEN return_cursor FOR SELECT 'a' FROM dual WHERE 1 = itemNumber; RETURN return_cursor; end test111; 使用如下sql返回
Time of Update: 2018-07-23
package com.test; import java.io.BufferedInputStream; import java.io.BufferedReader; import java.io.FileInputStream; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; import java.util.Date; /** *
Time of Update: 2018-07-23
1.查看Oracle最大串連數 SQL>show parameter processes #最大串連數 2.修改最大串連數 SQL>alter system set processes=value scope=spfile 重啟資料庫 SQL>shutdown force SQL>start force 3.查看當前串連數 SQL>select * from V$SESSION where username is not
Time of Update: 2018-07-23
oracle查詢使用者所有表記錄數 因現場需要升級應用,為安全起見先評估資料量,oracle,一條命令就能搞定。有個需要注意的,需要有DBA許可權的使用者才行。 select TABLE_NAME,NUM_ROWS from dba_all_tables order by num_rows desc如查詢某個使用者的:select TABLE_NAME,NUM_ROWS from dba_all_tables where owner='使用者大寫'