ORA-12560: TNS:protocol adapter error(TNS:协议适配器错误)
这种问题一般是因为客户端不知道要连那个instance或者不知道要使用哪个TNS Alias 可能的原因1.服务没有起来 下边是Tom的一个Test Case来说明OracleServiceSID服务没有起来的话,是会引起ORA-12560错误的。 C:\Documents and Settings\tkyte>sqlplus scott/tiger SQL*Plus: Release 10.1.0.4.0 - Production on Thu Sep 6 15:43:55 2007 Copyright (c) 1982, 2005, Oracle. All rights reserved. Connected to: Oracle Database 10g Enterprise E
The Tom Kyte Blog: When the explanation doesn't sound quite right...
Refer:http://tkyte.blogspot.com/2007/04/when-explanation-doesn-sound-quite.html I was asked recently Under what conditions, autotrace & explain plan can not give the correct execution plan of a sql? The question came in email - not via asktom. But I found it of enough general interest to write about it here. As an aside, I rarely, if ever, answer questions emailed to me directly. It just isn\'t a scalable solution. This is my attempt to make this
TKPROF解析
TKPROF命令之前我们收集的trace日志仍为Raw Trace,如果要做性能分析的话,往往要转换为TKPROF,TKPROF可以把Raw Trace转换为更易读的形式。TKPROF Command $tkprof tracefile outputfile [explain= ] [table= ] [print= ] [insert= ] [sys= ] [sort= ] ... Sample: TKPROF raw_trace.trc OUTPUTA.TKPROF EXPLAIN=scott/tiger SYS=NO SORT=(EXECPU,FCHCPU) tracefile:你要分析的trace文件outputfile:格式化后的文件explain=user/password@connectstring(
Exadata概览
为什么叫Exadata 为啥叫Exadata? 这是数据量的单位:从字节开始往上按照千分位递进,分别就是KiloByte(KB)、MegaByte(MB)、GigaByte(GB)、TeraByte(TB)、PetaByte(PB)、ExaByte(EB)、ZettaByte(ZB)、YottaByte(YB)。Exadata这个名字就是从ExaByte(EB)获取的灵感。 一些关于exadata的数据 2008年Oracle OpenWorld上发布的; Exadata全球销售额目前已经接近20亿美元; Exadata在上一个Oracle财年卖了28台,新一
Initialization Parameter files: PFILEs vs. SPFILEs
Initialization Parameter files: PFILEs vs. SPFILEs Submitted by admin on Sun, 2003-08-03 19:29 RDBMS Server When an Oracle Instance is started, the characteristics of the Instance are established by parameters specified within the initialization parameter file. These initialization parameters are either stored in a PFILE or SPFILE. SPFILEs are available in Oracle 9i and above. All prior releases of Oracle are using PFILEs. SPFILEs provide the following advantages over PFILEs:
TNSNAMES.ORA, LISTENER.ORA and SQLNET.ORA
Oracle uses three files (listener.ora, tnsnames.ora & sqlnet.ora) for network configuration. Oracle Net is configured by configuration files. These include (but are not limited to): TNSNAMES.ORA - This file contains a list of service names, which translate into the instances the client can connect to. It (tnsnames.ora) is used on outgoing requests.SQLNET.ORA - this file is used to configure Oracle Net on the client. For example, tracing can be turned on.LISTENER.ORA - T
EBS表后缀的意义
Object Name Function of the object E.g. _ALL Underlying table with all the values PO_DISTRIBUTIONS_ALL _B Base of underlying table, same as _ALL MTL_SYSTEM_ITEMS_B _TL Language translation table with translation of descriptive fields in different languages FND_RESPONSIBILITY_TL _VL View based on translation table,are views for multi language tables which combines the row of the base table with the corresponding row of the _TL table where the LANGUAGE = USER
事务时间(Sysdate)不对的解决方法
做库存事务,发现Transaction Date是2016年的一个时间 然后查了Sysdate,发现数据的时间确实不对 但查了下Unix Server的时间没有问题,是当前时间 -bash-3.2$ date Sun Mar 4 23:25:45 PST 2012 解决方法: 先设定一个固定的时间到系统 SQL> alter system set fixed_date =\'2012-03-03\' 2 / System altered.--- 再恢复系统时间 SQL> alter system set fixed_date = none 2 / System altered. 然后sysdate就返回了
如何解数据库锁
一些误操作可能会造成数据被锁,可以尝试用下边的脚本来解锁脚本可行,已经试用多次Column SID FORMAT 9999999 heading "Sess|ID " COLUMN SERIAL# FORMAT 9999999 heading "Serial# " COLUMN OBJECT_NAME FORMAT A17 heading "OBJ NAME or|TRANS_ID" Trunc COLUMN OSUSER FORMAT A10 heading "Op Sys|User ID" COLUMN USERNAME FORMAT A8 select B.SID, C.SERIAL#, C.USERNAME, C.OSUSER, DECODE(B.ID2, 0, A.OBJECT_NAME,\'Tran
Select for update, nowait, skip locked
FOR UPDATE NOWAIT BEGIN SELECT x FROM table FOR UPDATE NOWAIT; EXCEPTION WHEN OTHERS THEN <handle exception> END; FOR UPDATE(Wait model) BEGIN SELECT x FROM table FOR UPDATE; EXCEPTION WHEN OTHERS THEN <handle exception> END;