Thursday, July 9, 2020

ERROR While EXPDP (Oracle Restore) : ORA-39143: dump file "c:\**********\.dmp" may be an original export dump file

Error :

ORA-39001 : invalid argument value
ORA-39000 : bad dump file specification
ORA-39143: dump file "c:\**********\.dmp" may be an original export dump file

I faced this error while importing (impdp) oracle dump in database using impdp command, and there is no error in Command

impdp remap_schema=OLD:NEW exclude=statistics remap_tablespace=OLD:NEW DIRECTORY=MY_DIR_ABC DUMPFILE=expdpDumpFile.dmp LOGFILE=TodayLogs.log PARALLEL=8 EXCLUDE=INDEX

Cause :

We need to concentrate on error ORA-39143: dump file "c:\**********\.dmp" may be an original export dump file. Where we can able to find actual root cause of the issue. Here condition is we are not aware the the backup was taken using exp or expdp.
If above error is appear then the dump (backup) is taken using command "exp"

Solution:

Use IMP command to restore the database:

imp Sys as sysdba/Password FROMUSER=OLD TOUSER=NEW file=expdpDumpFile.dmp ignore=y indexes=n statistics=none constraints=n log=TodayLogs.log grants=n

Monday, July 6, 2020

Generate Multiple copy of Document/Files

Requirement :

Here i faced requirement, that i need multiple duplicate organization for R&D purpose. Where the Document name should have some sequence like 1,2,3,4

I was searching for open source tool to generate random files but those are giving random names to file.

So i used simple CMD command to generate files, it is quite easy:

We just need to pass the file name, i opt for file which is having same in size and extension of PDF.

Open CMD and run below command:

for /l %A in (1,1,2000) do copy "D:\Duplicate\file.PDF" "D:\Duplicate\file-%A.PDF"
web stats