Monday, February 27, 2017

ORA-16191: Primary log shipping client not logged on standby

We were getting some issues that primary was getting error in DGMGRL

ORA-16191: Primary log shipping client not logged on standby

and on DR DGMGRL was


RFS[1]: Assigned to RFS process (PID:29063)
RFS[1]: Possible network disconnect with primary database

The resolution is stop the DR and start in mount mode and wait for archive logs to be applied. Once they are applied then. Stop the DR database and start it up with srvctl 

Done!

Friday, February 10, 2017

FRM-91500: Unable to start/complete the build

Trying to compile the form but getting error

Terminal map initialization failed.
API: could not initialize character-mode driver.
FRM-91500: Unable to start/complete the build.
ERRORS DURING GENERATION - skipping MYFORM.fmb

I am using SecureCRT.

Solution:

I just resized the SecureCRT window from full screen to bit smaller and it worked all good !!!

Thursday, February 2, 2017

Getting error The Activity Monitor is unable to execute queries against server

TITLE: Microsoft SQL Server Management Studio
------------------------------

The Activity Monitor is unable to execute queries against server sqldb01\SALES.
Activity Monitor for this instance will be placed into a paused state.
Use the context menu in the overview pane to resume the Activity Monitor.

------------------------------
ADDITIONAL INFORMATION:

Timeout expired.  The timeout period elapsed prior to completion of the operation or the server is not responding.
The statement has been terminated. (Microsoft SQL Server, Error: -2)

For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft%20SQL%20Server&ProdVer=11.00.6020&EvtSrc=MSSQLServer&EvtID=-2&LinkId=20476

------------------------------

The wait operation timed out

------------------------------
BUTTONS:

OK
------------------------------


Reason behind is that you are running activity monitor from cluster, log on to the node and run activity monitor there and there will be no issues at all.

Error message is PLS-00201: identifier 'DBMS_CRYPTO' must be declared

The issue is unable to compile the function used for cryptography and getting error

SQL> alter FUNCTION user1.mycryp compile;

Warning: Function altered with compilation errors.

SQL>

Error message is PLS-00201: identifier 'DBMS_CRYPTO' must be declared.


Solution:

Simple grant execute on sys.DBMS_CRYPTO to user1 by

SQL> grant execute on sys.DBMS_CRYPTO to user1;

Grant succeeded.

SQL>


Done!!!

SQL> alter FUNCTION  user1.mycryp compile;

Function altered.

SQL>

Wednesday, February 1, 2017

Encountering error ORA-39082 while performing the import

Getting error ORA-39082 while perfoming the import

ORA-39082: Object type FUNCTION:"HARVEY"."MY_DETAILS" created with compilation warnings
ORA-39082: Object type FUNCTION:"HARVEY"."MY_DETAILS" created with compilation warnings
ORA-39082: Object type VIEW:"HARVEY"."V_MY_DETAILS" created with compilation warnings

I was trying to import the schema twice and getting the error second time as second time I was importing contents to new schema and tablespace. I was using remap_schema and remap_tablespace. It turned out that it was a coding issue. Because the function had a fully qualified object name and in second import it was referring to the previous object and resulting in "PLS-00364: loop index variable 'string' use is invalid".

The fix was after import change the function and modify to point to new object and view was dependent on it and the compiling it to fix it.

Getting error while doing impdp ORA-39083: Object type TYPE failed to create with error

I was getting the error while perfomring improt

ORA-39083: Object type TYPE:"HARVEY"."HARTYP_COLUMN" failed to create with error:
ORA-02304: invalid object identifier literal
Failing sql is:
CREATE EDITIONABLE TYPE "HARVEY"."HARTYP_COLUMN"   OID '3EB78B505CC15B2EE0531560060A482A' AS OBJECT (
  col  NUMBER (19, 0)
);
ORA-39083: Object type TYPE:"HARVEY"."HARTYP_RECORD" failed to create with error:
ORA-02304: invalid object identifier literal
Failing sql is:
CREATE EDITIONABLE TYPE "HARVEY"."HARTYP_RECORD"   OID '3EB7A19BA0923593E0531560060AABAA' AS OBJECT (
  component  VARCHAR2 (20)
 ,from_id    NUMBER (19, 0)
 ,new_id     NUMBER (19, 0)
);
ORA-39083: Object type TYPE:"HARVEY"."RMTYP_STRING" failed to create with error:
ORA-02304: invalid object identifier literal
Failing sql is:
CREATE EDITIONABLE TYPE "HARVEY"."RMTYP_STRING"   OID '3EC89CAF1D642B69E0531760060AD984' AS VARRAY(200) OF NVARCHAR2(2000);
ORA-39083: Object type TYPE:"HARVEY"."RMTYP_TABLE" failed to create with error:
ORA-02304: invalid object identifier literal
Failing sql is:
CREATE EDITIONABLE TYPE "HARVEY"."RMTYP_TABLE"   OID '3EB78B505CC55B2EE0531560060A482A' AS TABLE OF HARTYP_COLUMN;
ORA-39083: Object type TYPE:"HARVEY"."RMTYP_MAPTABLE" failed to create with error:
ORA-02304: invalid object identifier literal
Failing sql is:
CREATE EDITIONABLE TYPE "HARVEY"."RMTYP_MAPTABLE"   OID '3EB7A19BA0983593E0531560060AABAA' AS TABLE OF HARTYP_RECORD


Reason:

This error occurs was occuring because I was doing the remap_schema and remap_tablespace .

In order of fix this what I have done was introduced a parameter in impdp which is transform=OID:n the default value is OID:y which means copy the original tablespace location.

Stating transform=OID:n means do not copy the original tablespace location because we are moving to different tablespace.

and the import was all good.