Oracle備忘錄

◆◆[b][color=red]Oracle10G管理界面登錄網址:[/color][/b]
http://localhost:1158/em/console/logon
http://localhost:5500/em/console/logon


◆◆[b][color=red]Oracle10G查看字符集:[/color][/b]
select * from nls_database_parameters


◆◆[b][color=red]Oracle默認用戶密碼:[/color][/b]
sys/change_on_install
system/manager
scott/tiger


◆◆[b][color=red]Oracle執行Sql語句列表:[/color][/b]

select *
from v$sql t
where t.FIRST_LOAD_TIME > to_char(sysdate - 1, 'yyyy-mm-dd hh24:mi:ss')
or t.LAST_LOAD_TIME > to_char(sysdate - 1, 'yyyy-mm-dd hh24:mi:ss');



◆◆[b][color=red]查看oracle數據庫是否啓動了刷新進程:[/color][/b]

select value from sys.v_$system_parameter where name = 'job_queue_processes';



◆◆[b][color=red]oracle的字符儲存---按字節或按字符[/color][/b]

+--------------------------------------------------+
+ 數據庫裏的varchar2和char字段長度定義是有兩種方式 +
+--------------------------------------------------+
+ 按字節 + 按字符 +
+-------------------------+------------------------+
+ varchar2(n byte) + +
+ char(n byte) + varchar2(n char) +
+ varchar2(n) + char2(n char) +
+ char2(n) + +
+-------------------------+------------------------+
+ substrb + substr +
+ lengthb + length +
+-------------------------+------------------------+



◆◆[b][color=red]oracle的translate函數的應用[/color][/b]
◇使用描述:過濾字符內容中的所有數字
◇執行語句:select translate('a1b2c3', '\1234567890', '\') from dual;
◇輸出結果:abc

◇使用描述:過濾字符內容中的除數字以外的字符
◇執行語句:select translate('a1b2c3','\' || translate('a1b2c3', '\1234567890', '\'),'\') from dual;
◇輸出結果:123
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章