Oracle 19.5 giving ORA-39358 for 19.0 dump - oracle

I am importing 19.0 dump (exported on Oracle 19.0c) on Oracle 19.5c oracle. But it give strange message as below,
Import: Release 19.0.0.0.0 - Production on Wed Mar 23 05:46:48 2022
Version 19.5.0.0.0
Copyright (c) 1982, 2019, Oracle and/or its affiliates. All rights reserved.
Connected to: Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
ORA-39002: invalid operation
ORA-39358: Export dump file version 19.0.0.0.0 not compatible with target version 12.2.0.0.0
Can anyone explain.
Here is the compatible parameter I have:
\`SQL\> SELECT name, value FROM v$parameter
WHERE name = 'compatible'; 2
NAME
-
VALUE
-
compatible
12\.2.0
\`

Related

My question is about exportdump with a query on oracle 9i

I am getting the following error and i need help.
hcp7 (spar)/tmp $ exp system/puppy parfile=rr.prm
Export: Release 9.2.0.8.0 - Production on Thu Oct 31 13:27:11 2019
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
Connected to: Oracle9i Enterprise Edition Release 9.2.0.8.0 - 64bit Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.8.0 - Production
Export done in US7ASCII character set and AL16UTF16 NCHAR character set
About to export specified tables via Conventional Path ...
Current user changed to AHS
. . exporting table HB_CONTROL_OUT_DATA
EXP-00056: ORACLE error 933 encountered
ORA-00933: SQL command not properly ended
Export terminated successfully with warnings.
hcp7 (spar)/tmp $
hcp7 (spar)/tmp $ vi rr.prm
"rr.prm" 6 lines, 258 characters
file=raj.dmp
log=raj.log
STATISTICS=none
compress=y
tables=AHS.HB_CONTROL_OUT_DATA
query="[select * from hb_control_out_data where exists (select '1' from hb_control_out where hbod_tran_num = hbo_tran_num and ADD_MO
NTHS(HBO_TO_MIS_DATE,24) >SYSDATE)]"
You need to escape your quotes in the query. See the documentation at https://docs.oracle.com/cd/B10501_01/server.920/a96652/ch01.htm#1005843.
BTW, version 9i belongs in a software museum. It was released 17 years ago and the final patch set was released over 12 years ago.
The error message is
EXP-00056: ORACLE error 933 encountered
ORA-00933: SQL command not properly ended
What SQL are you executing? Well, your parameter file includes a QUERY parameter. It may be a trick of the cut'n'paste into the StackOverflow question box but this looks odd:
ADD_MO NTHS(HBO_TO_MIS_DATE,24)
^
If that space or newline is not an artefact remove and re-run the export.

What is the version number of Oracle 18c?

Oracle changed the release schedule for their database, announcing that version 12.2.0.2 will be called "Oracle Database 18c."
What is the version number of the database, 12.2.0.2 or 18.x.x.x?
Internally 18c identifies itself as version 18.
On API level:
$ cat /u01/app/oracle/product/18.1.0.0/dbhome_1/rdbms/public/ociver.h
#ifndef OCIVER_ORACLE
#define OCIVER_ORACLE
#define OCI_MAJOR_VERSION 18 /* Major release version */
#define OCI_MINOR_VERSION 0 /* Minor release version */
#endif
And also on SQL level:
SQL> SELECT VERSION FROM PRODUCT_COMPONENT_VERSION;
VERSION
----------
18.0.0.0.0
And also on JDBC level:
java -jar /u01/app/18.1.0.0/grid/jdbc/lib/ojdbc8.jar
Oracle 18.0.0.0.0 JDBC 4.2 compiled with javac 1.8.0_152 on Wed_Dec_06_05:42:32_PST_2017
#Default Connection Properties Resource
#Thu May 31 12:52:24 CEST 2018
Ah, found it, the database is not yet available for download, but livesql says
SELECT * FROM v$version;
Oracle Database 18c Enterprise Edition Release 18.0.0.0.0 - Production
EDIT: Hmm, the documentation for 18c is online, but it refers in the text to 12c, for instance
46.2 DBMS_DB_VERSION Constants
The Oracle Database 12c Release 2 version of the DBMS_DB_VERSION package uses the constants shown in the following table.

VARCHAR2 field and NVARCHAR2 exsit in the same table,the former is correct,the latter was garbled

the database A field Type is:
select column_name,data_type From all_tab_columns ;
COLUMN_NAME DATA_TYPE
------------------------------------
NAME VARCHAR2
ID_ISSUE_PLACE VARCHAR2
NATIONALITY NVARCHAR2
I want to export a table with expdp:
expdp abc/123 tables=A.CUST:PARTNUM_0 exclude=grant,index,contraint,statistics,trigger DIRECTORY=DATATMP filesize=100M dumpfile=expdp_%U.dmp parallel=4 cluster=N COMPRESSION=DATA_ONLY
Then,I import the dmp file to my local oracle,the field 'NATIONALITY' is correct , but the other field is garbled.
impdp abc/123 DIRECTORY=DATATMP DUMPFILE=expdp_01.dmp
[oracle#db01 tmp]$ impdp bi71/bi71 DIRECTORY=datatmp
DUMPFILE=expdp_01.dmp
Import: Release 11.2.0.1.0 - Production on Tue Sep 6 11:18:05 2016
Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights
reserved.
Connected to: Oracle Database 11g Enterprise Edition Release
11.2.0.1.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options Master table
"A"."SYS_IMPORT_FULL_01" successfully loaded/unloaded Starting
"A"."SYS_IMPORT_FULL_01": abc/******** DIRECTORY=datatmp
DUMPFILE=expdp_01.dmp Processing object type TABLE_EXPORT/TABLE/TABLE
Processing object type TABLE_EXPORT/TABLE/TABLE_DATA . . imported
"A"."CUST":"PARTNUM_0" 5.990 MB 78037 rows
Statement:Not a windows client problems,because the vietnamese charecter has been displayed properly.Here with reason screenshot windows client, is to make the results better clarity.
screenshot
I found a rule,once vietnamese nationality in this line appears,the field NAME,ID_ISSUE_PLACE are garbled.
How to resolve? thanks(^_^).

How to check Oracle patches are installed?

How do I check that all services and patches are installed in Oracle?
I have an Oracle 10.2.0.2.0 db version and want to install patches. Also I want to get a list with all services and patches.
Here is an article on how to check and or install new patches :
To find the OPatch tool setup your database enviroment variables and then issue this comand:
cd $ORACLE_HOME/OPatch
> pwd
/oracle/app/product/10.2.0/db_1/OPatch
To list all the patches applies to your database use the lsinventory option:
[oracle#DCG023 8828328]$ opatch lsinventory
Oracle Interim Patch Installer version 11.2.0.3.4
Copyright (c) 2012, Oracle Corporation. All rights reserved.
Oracle Home : /u00/product/11.2.0/dbhome_1
Central Inventory : /u00/oraInventory
from : /u00/product/11.2.0/dbhome_1/oraInst.loc
OPatch version : 11.2.0.3.4
OUI version : 11.2.0.1.0
Log file location : /u00/product/11.2.0/dbhome_1/cfgtoollogs/opatch/opatch2013-11-13_13-55-22PM_1.log
Lsinventory Output file location : /u00/product/11.2.0/dbhome_1/cfgtoollogs/opatch/lsinv/lsinventory2013-11-13_13-55-22PM.txt
Installed Top-level Products (1):
Oracle Database 11g 11.2.0.1.0
There are 1 products installed in this Oracle Home.
Interim patches (1) :
Patch 8405205 : applied on Mon Aug 19 15:18:04 BRT 2013
Unique Patch ID: 11805160
Created on 23 Sep 2009, 02:41:32 hrs PST8PDT
Bugs fixed:
8405205
OPatch succeeded.
To list the patches using sql :
select * from registry$history;
I understand the original post is for Oracle 10 but this is for reference by anyone else who finds it via Google.
Under Oracle 12c, I found that that my registry$history is empty.
This works instead:
select * from registry$sqlpatch;
Maybe you need "sys." before:
select * from sys.registry$history;

INTERNAL ERROR :Failed assertion [PGE code :90105]

While trying to compile sample code with the Pro*C compiler I am getting:
c:\oracle\product\11.2.0\dbhome_1\BIN>proc iname=C:\Users\Selvaganapathy\Desktop
\pro-c\code\sample.pc
Pro*C/C++: Release 11.2.0.1.0 - Production on Mon Aug 6 01:00:59 2012
Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.
System default option values taken from: C:\oracle\product\11.2.0\dbhome_1\preco
mp\admin\pcscfg.cfg
INTERNAL ERROR: Failed assertion [PGE Code=90105]
Please help to set up the compiler.
Check if you have the temporary file
C:\Users\Selvaganapathy\Desktop\pro-c\code\sample.c
If it exists, retry after deleting this file or provide write permission to it.

Resources