Thursday, September 27, 2012

Error While configuring "emca"

C:\Documents and Settings\user> emca -config dbcontrol db -repos create

STARTED EMCA at **** **:**:** PM
EM Configuration Assistant, Version 11.2.0.0.2 Production
Copyright (c) 2003, 2005, Oracle. All rights reserved.

Enter the following information:
Database SID: orcl
Exception in thread "main" oracle.sysman.emcp.exception.DatabaseUnavailableException: Database instance unavailable.
at oracle.sysman.emcp.DatabaseChecks.throwDBUnavailableException(DatabaseChecks.java:151)
at oracle.sysman.emcp.DatabaseChecks.checkDbAvailabilityImpl(DatabaseChecks.java:144)
at oracle.sysman.emcp.DatabaseChecks.checkDbAvailability(DatabaseChecks.java:163)
at oracle.sysman.emcp.DatabaseChecks.getDbServiceName(DatabaseChecks.java:582)
at oracle.sysman.emcp.EMConfigAssistant.performConfiguration(EMConfigAssistant.java:1272)
at oracle.sysman.emcp.EMConfigAssistant.statusMain(EMConfigAssistant.java:574)
at oracle.sysman.emcp.EMConfigAssistant.main(EMConfigAssistant.java:522)

orcl is the oracle sid on my computer and database status is RUNNING
                                                                  ----------------------------


                                                                  ----------------------------
C:\Documents and Settings\*****>emctl
EM Configuration issue. E:\app\*****\product\11.2.0\dbhome_1/*****_orcl not found.

Due to this error ... "emctl start dbconsole" throws error.



SOLUTION
configuring the Enterprise Manager using DBCA ?

dbca->configure database options -> "select the database" -> Configure Enterprise Manager



Saturday, September 15, 2012

Enabling Remote Connections for MSsql

unable to connect with sql server remotely (using sql developer or other jdbc connections)

 “Cannot connect to SQL-Server-Instance-Name
Login failed for user ‘username‘.

Step-by-step
1.Open SQL Server Configuration Manager.
         Click Start -> Programs -> Microsoft SQL Server 2008 -> Configuration Tools ->SQL Server   Configuration Manager.
2.Start sqlserver services.
3.On the left window, expand SQL Server Network Configuration -> Protocols for                                  SQLEXPRESS. You see that TCP/IP protocol status is disabled.
4.Right-click on TCP/IP and select Enable to enable the protocol.
5.There is a pop-up shown up that you have to restart the SQL Service to apply changes.
6.On the left window, select SQL Server Services. Select SQL Server (SQLEXPRESS) on the right window -> click Restart. The SQL Server service will be restarted.

Sunday, September 9, 2012

Full Text Index error

SQL> create table t ( a nvarchar2(2000));

Table created.

SQL>
SQL>
SQL> create index idx on t(a) indextype is ctxsys.context;
create index idx on t(a) indextype is ctxsys.context
*
ERROR at line 1:
ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
ORA-20000: Oracle Text error:
DRG-10509: invalid text column: A
ORA-06512: at "CTXSYS.DRUE", line 160
ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 364


solution
Change datatype of column to 'blob' or 'clob'
then try again

Sunday, September 2, 2012

dbms_metadata.get_ddl Not DisPlay full query

SQL> select dbms_metadata.get_ddl('TABLE','DEPT','SCOTT') from dual;

DBMS_METADATA.GET_DDL('TABLE','DEPT','SCOTT')
--------------------------------------------------------------------------------

CREATE TABLE "SCOTT"."DEPT"
( "DEPTNO" NUMBER(2,0),
"DNAME" VARCHAR2(14

solve::

set heading off;
set echo off;
Set pages 999;
set long 90000;

select dbms_metadata.get_ddl('TABLE','DEPT','SCOTT') from dual;

web stats