Imp command
i want to import a dmp file which contains 3 tables to a user named "test", i opened a cmd window and i wrote “imp” then i specified the file path, but when i connect to that user i can not find the tables that were exported in the dmp file although at the cmd window there were not any error or warning while executing the imp command, any help??
Is the import log file contents generated ...as expected...???
I mean specific export file imported to specific db user... according to the log file....????
Are there any errors....????
Sim
Similar Messages
-
Export / import exp / imp commands Oracle 10gXE on Ubuntu
I have Oracle 10gXE installed on Linux 2.6.32-28-generic #55-Ubuntu, and I need soe help on how to export / import the base with exp / imp commands. The commands seems to be installed on */usr/lib/oracle/xe/app/oracle/product/10.2.0/server/bin* directory but I cannot execute them.
The error message I got =
No command 'exp' found, did you mean:
Command 'xep' from package 'pvm-examples' (universe)
Command 'ex' from package 'vim' (main)
Command 'ex' from package 'nvi' (universe)
Command 'ex' from package 'vim-nox' (universe)
Command 'ex' from package 'vim-gnome' (main)
Command 'ex' from package 'vim-tiny' (main)
Command 'ex' from package 'vim-gtk' (universe)
Command 'axp' from package 'axp' (universe)
Command 'expr' from package 'coreutils' (main)
Command 'expn' from package 'sendmail-base' (universe)
Command 'epp' from package 'e16' (universe)
exp: command not found
Is there something I have to do ?Hi,
You have not set environment variables correctly.
http://download.oracle.com/docs/cd/B25329_01/doc/install.102/b25144/toc.htm#BABDGCHH
And of course that sciprt have small hickup, so see
http://ubuntuforums.org/showpost.php?p=7838671&postcount=4
Regards,
Jari -
Imp Command to import a single table
Dear All:
i want to import a single table from my backup and want to preserve all the existing indexes using IMP command.
UserID : NEW_USER
PWD: qwert1imp system/password@tstdhk fromuser=syslog touser=newuser tables=logs200712 rows=y file=/u06/import_exp/syslog_logs200712_080217.dmp commit=Y grants=N statistics=NONE ignore=Y log=/u06/import_exp/logs_part_jan.log
Regards
Asif Kabir -
Execute exp&imp command by store procedure
Dear all,
I have some statements to run before and after exp&impdata.
Is there anyway to execute exp&imp command in store procedure,Pls show me.
example
CREATE OR REPLACE PROCEDURE test
BEGIN
update ....
exp user/passwd ....
delete ...
END ;
Oracle 10g on solaris10
Thank you for advance
CharaHi,
Since you are working with Oracle10gm you may check DBMS_DATAPUMP:
http://download.oracle.com/docs/cd/B19306_01/appdev.102/b14258/d_datpmp.htm
Or like any shell command, you can use java programs.
Saad,
http://saadnayef.blogspot.com -
Importing master repositrory using imp command
Hi,
I am trying to import the master repository using the imp command.It prompts for a username/password.I give the master repository schema name and password.Then it asks for the input file.
Import file: EXPDAT.DMP >
Please tell me whether the (exported)repistory folder/zip file should be in a specific directory.Thanks BarisYildirim & 000000
I checked all things as you mentioned above guys, Is anything else I need to do. -
Imp command and some warnings....
C:\temp>imp userid=system file=FIERROSXY.DMP log=imp.log fromuser=UFIERROS touser=UFIERROS
Connected to: Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production
Export file created by EXPORT:V10.01.00 via conventional path
Warning: the objects were exported by UFIERROS, not by you
import done in WE8MSWIN1252 character set and AL16UTF16 NCHAR character set
. importing UFIERROS's objects into UFIERROS
. . importing table "AUTORIZA" 0 rows imported
. . importing table "BANCOS" 0 rows imported
. . importing table "CG_FORM_HELP" 0 rows imported
. . importing table "CG_REF_CODES" 0 rows imported
. . importing table "CIERRES" 0 rows imported
. . importing table "CIERRES_DETALLES" 0 rows imported
. . importing table "CLASIFICACIONES_GANADOS" 0 rows imported
. . importing table "CONDUENIOS" 0 rows imported
. . importing table "CORTES" 0 rows imported
. . importing table "CORTES_DETALLES" 0 rows imported
. . importing table "CORTES_INSTRUMENTOS" 0 rows imported
. . importing table "CUENTAS_CONTABLES" 0 rows imported
. . importing table "DOA_PICTUREDEMO" 0 rows imported
. . importing table "EMISORAS" 0 rows imported
. . importing table "FIERROS" 91324 rows imported
. . importing table "FIERROS_CLAS" 0 rows imported
. . importing table "FIERROS_IMAGEN" 103181 rows imported
IMP-00017: following statement failed with ORACLE error 959:
"CREATE TABLE "FIERROS_IMAGEN_BLOB" ("FIERROS_ID" NUMBER(7, 0), "IMAGEN" BLO"
"B, "ESTATUS" VARCHAR2(1)) PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 ST"
"ORAGE(INITIAL 65536 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT) TABL"
"ESPACE "DESA_DAT" LOGGING NOCOMPRESS LOB ("IMAGEN") STORE AS (TABLESPACE ""
"DESA_DAT" ENABLE STORAGE IN ROW CHUNK 8192 PCTVERSION 10 NOCACHE STORAGE(I"
"NITIAL 65536 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT))"
IMP-00003: ORACLE error 959 encountered
ORA-00959: tablespace 'DESA_DAT' does not exist
. . importing table "FIRMAS" 8952 rows imported
. . importing table "FIRMAS_CONDUENIOS" 0 rows imported
. . importing table "FI_CARACTER" 0 rows imported
. . importing table "FI_DIBUJO" 0 rows imported
. . importing table "FI_PRUEBA" 0 rows imported
. . importing table "FI_SIMBOLO" 0 rows imported
. . importing table "FOLIOS" 0 rows imported
. . importing table "GANADOS_ESPECIES" 0 rows imported
. . importing table "GANADOS_FIERROS" 0 rows imported
. . importing table "GANADO_PROPOSITOS" 0 rows imported
. . importing table "GANADO_RAZAS" 0 rows imported
. . importing table "GANADO_TIPOS" 20 rows imported
. . importing table "INFRAESTRUCTURAS" 0 rows imported
. . importing table "LOTE_FOLIOS" 0 rows imported
. . importing table "MEDIOS_TRANSPORTE" 7 rows imported
. . importing table "MOVIMIENTOS_FIERROS" 344326 rows imported
. . importing table "MOVIMIENTOS_PAGOS" 0 rows imported
. . importing table "MUNICIPIOS" 70 rows imported
. . importing table "NIST" 0 rows imported
. . importing table "OPERACIONES_CAJAS" 0 rows imported
. . importing table "OPERACIONES_MOVIMIENTOS" 0 rows imported
. . importing table "PARAMETROS_SISTEMA" 0 rows imported
. . importing table "PASE_DETALLE" 0 rows imported
. . importing table "PASE_MAESTRO" 0 rows imported
. . importing table "SANIDAD_DETALLE" 0 rows imported
. . importing table "TARIFA_GANADO" 0 rows imported
. . importing table "TCERTORIG" 20 rows imported
. . importing table "TIPOS_INFRAESTRUCTURAS" 0 rows imported
. . importing table "TIPOS_INSTRS_PAGOS" 0 rows imported
. . importing table "TIPOS_MOVIMIENTO" 15 rows imported
. . importing table "TIPOS_SANIDAD" 0 rows imported
. . importing table "TIPOS_SOLICITUDES" 0 rows imported
. . importing table "TIPO_GANADO" 33 rows imported
. . importing table "TIPO_SOLICITUD" 0 rows imported
. . importing table "USUARIOS" 0 rows imported
About to enable constraints...
Import terminated successfully with warnings.
some questions about:
(First i use oracle XE on windows and the file FIERROSXY.DMP are exported from Oracle 10g)
1) need create before the tablespace DESA_DAT ? if yes, where create? i know these command:
create tablespace DESA_DAT datafile 'C:\oracle\product\10.1.0\oradata\FIERROS\DESA_DAT.DBF' size 16M autoextend on next 16M maxsize 1024M segment space man agement auto extent management local;
if you see i need specify the path.... if i havent the database FIERROS i havent a path... right?
if not, wich commands need for create the table space?
2) for rerun the command first i need drop the user Fierros, then recreate it, grant some privileges, to user... and then rerun the command right?
3) anyway get warnings, the data is imported???
thankssome questions about:
(First i use oracle XE on windows and the file
FIERROSXY.DMP are exported from Oracle 10g)
1) need create before the tablespace DESA_DAT ? if
yes, where create? i know these command:
create tablespace DESA_DAT datafile
'C:\oracle\product\10.1.0\oradata\FIERROS\DESA_DAT.DBF
' size 16M autoextend on next 16M maxsize 1024M
segment space man agement auto extent management
local;
if you see i need specify the path.... if i havent
the database FIERROS i havent a path... right?
if not, wich commands need for create the table
space?
2) for rerun the command first i need drop the user
Fierros, then recreate it, grant some privileges, to
user... and then rerun the command right?
3) anyway get warnings, the data is imported???
thanks1) No tablespace don't have to exist before import. However with one exception that is you have LOB data type in your table.
You need to precreate the tablespace
or precreate the table with LOB type in different tablespace.
2) You only need to import the table that failed, in your case, FIERROS_IMAGEN_BLOB
3) Yes, except the table report error, other tables are ok -
O/s commands from PL/SQL
hi all..
i want to execute operating system commands from PL/SQL..
particulary imp command....
i have used the f/wg approach but while i execute the imp command it does not responds me any output..
I have to kill the process from o/s.
prodn is my user
--AS SYS user
begin
dbms_java.grant_permission( 'PRODN',
'SYS:java.io.FilePermission',
'/oracle/product/9.2.0/bin/imp',
'execute' );
dbms_java.grant_permission
('PRODN',
'java.lang.RuntimePermission',
'writeFileDescriptor' );
end;
---------------------------------AS PRODN user
create or replace and compile
java source named "Util"
as
import java.io.*;
import java.lang.*;
public class Util extends Object
public static int RunThis(String args)
Runtime rt = Runtime.getRuntime();
int rc = -1;
try
Process p = rt.exec(args);
int bufSize = 4096;
BufferedInputStream bis = new BufferedInputStream(p.getInputStream(),
bufSize);
int len;
byte buffer[] = new byte[bufSize];
// Echo back what the program spit out
while ((len = bis.read(buffer, 0, bufSize)) != -1)
System.out.write(buffer, 0, len);
rc = p.waitFor();
catch (Exception e)
e.printStackTrace();
rc = -1;
finally
return rc;
create or replace
function RUN_CMD(p_cmd in varchar2) return number
as
language java
name 'Util.RunThis(java.lang.String) return integer';
create or replace procedure RC(p_cmd in varchar2)
as
x number;
begin
x := run_cmd(p_cmd);
end;
i executed the command as follows in sql>
BEGIN
rc('/oracle/product/9.2.0/bin/imp tim/tim file=/home/oracle/vas4359.dmp log
=log1.log');
END;
it runs fine creates log1.log in / home/oracle but there is no output in
log1.log file.
I have to kill the process as follows after which sql> displays me :
"PL/SQL procedure successfully completed."
[oracle@msebdb oracle]$ ps aux|grep imp
oracle 20052 0.0 0.2 12732 4328 ? S 11:57 0:00 /oracle/product/
.2.0/bin/imp file=/home/oracle/vas4359.dmp log=log1.log
oracle 20102 0.0 0.0 3692 652 pts/2 S 12:03 0:00 grep imp
Note:There is no tim user.. i just want to get error in my log file..
my further steps are to read this log file and send email/notifications to users.
my main program is as f/ws:
/*imp and check log file*/
create or replace procedure abc
as
v_exists boolean;
v_exists_log boolean;
ex_open BOOLEAN;
flen NUMBER;
bsize NUMBER;
vInHandle_open utl_file.file_type;
vInHandle_open_log utl_file.file_type;
v_filelog utl_file.file_type;
v_fl utl_file.file_type;
v_pth varchar2(60);
v_fnm varchar2(60);
v_file_exists varchar2(60);
v_logline varchar2(30) ;
v_search varchar2(30) :='ORA-';
vNewLine VARCHAR2(32767);
cursor c_fname is
select full_pth ,f_name from upld_file_t where f_name in
(select f_name from tbl_file_nm where typ_file='D' AND DEL_FLG='N');
BEGIN
for v_sec in c_fname
loop
utl_file.fgetattr(LOCATION=>'ORALOAD',
FILENAME=>v_sec.f_name,
FEXISTS=>v_exists,
FILE_LENGTH=> flen,
BLOCK_SIZE=>bsize);
if v_exists
THEN
dbms_output.put_line('File Exists' || v_sec.f_name);
v_file_exists:=v_sec.f_name;
--dbms_output.put_line('v_file_exists ' || v_file_exists);
dbms_output.put_line('File Length: ' || TO_CHAR(flen));
dbms_output.put_line('Block Size: ' || TO_CHAR(bsize));
dbms_output.put_line(' before file open');
vInHandle_open := utl_file.fopen('ORALOAD',v_sec.f_name,'R',32767);
-- dbms_output.put_line(' after file open');
-- do whater with teh file data
v_fl:=utl_file.fopen('ORALOAD','v_sec.f_name','W');
dbms_output.put_line('v_sec.f_name');
IF utl_file.is_open(vInHandle_open)
THEN
/*if log file exists..*/
utl_file.fgetattr(LOCATION=>'ORALOAD',
FILENAME=>v_sec.f_name||'.log',
FEXISTS=>v_exists_log,
FILE_LENGTH=> flen,
BLOCK_SIZE=>bsize);
if v_exists_log
then
dbms_output.put_line('file' ||v_sec.f_name||'.log');
v_filelog :=utl_file.fopen('ORALOAD',v_sec.f_name||'.log','W',32767);
LOOP
BEGIN
UTL_FILE.PUT(v_filelog,'ORA-');
exit;
END;
END LOOP;
else
dbms_output.put_line('File not found' || v_sec.f_name);
END IF;
UTL_FILE.fclose(v_filelog);
dbms_output.put_line('Closed File ' || v_sec.f_name|| '.log');
END IF;
/*imp THE FILE and read log file*/
utl_file.fgetattr(LOCATION=>'ORALOAD',
FILENAME=>v_sec.f_name||'.log',
FEXISTS=>v_exists_log,
FILE_LENGTH=> flen,
BLOCK_SIZE=>bsize);
if v_exists_log
then
dbms_output.put_line('file' ||v_sec.f_name||'.log');
v_filelog :=utl_file.fopen('ORALOAD',v_sec.f_name||'.log','R',32767);
LOOP
BEGIN
UTL_FILE.get_line(v_filelog,v_logline);
if v_logline = v_search then
dbms_output.put_line(v_logline);
end if;
UTL_FILE.fclose(v_filelog);
dbms_output.put_line('Closed File ' || v_sec.f_name|| '.log');
exit;
END;
END LOOP;
else
dbms_output.put_line('File not found' || v_sec.f_name);
END IF;
END IF;
END LOOP;
--close the curosr .. check this
EXCEPTION
WHEN UTL_FILE.ACCESS_DENIED THEN
DBMS_OUTPUT.PUT_LINE('No Access!!!');
when others then
dbms_output.put_line('ERROR (open_file) => '||sqlcode);
dbms_output.put_line('MSG (open_file) => '||sqlerrm);
end;Hi,
You might have better luck in the PL/SQL or Java forums. They are located here:
PL/SQL: PL/SQL
Java: http://forums.oracle.com/forums/forum.jsp?forum=99
Good luck,
Mark -
Issue with triggers while importing (imp) to another user
hi all,
we have two oracle databases (oracle 10g R2)
1. production
2. test (clone of production)
whenever we need to update the test database for the developers we take a full export dump of the production (hardly 20GB) and import the same into test after dropping the tables in the required schema
export system/***@production file=exp.dmp log=log.log full=y statistics=nonewe have a schema named user1, in production.
same is the case in test
I got a request to refresh the user1 schema in test, but with a different schema user2 (new schema created), as there was some critical dev. work going on with user1 schema.
hence i didnt want to touch the user1 schema in test environment & after taking an export dump of the production i didnt import it into the same schema.
i imported the dump data to user 2 schema
imp system/***@test file=exp.dmp log=implog.log fromuser=user1 touser=user2 statistics=nonethe moment i did this developers working with user1 schema started facing issues when their code hit triggers on user1 schema. all insert/update triggers in the user1 schema started pointing to corresponding tables in user2.
any clues why something like this happened? what was the mistake in he imp command i used?
thanks for your timeHi,
Check for the trigger source in your original schema. If it has schema name mentioned before the tables on which the trigger is created, it would create problem during import. While importing, it will reference the previous schema , though you are importing it in new schema.
If this is the case, remove the schema name from the source and then export and re import.
Regards
Vinitaa -
Problem with imp in 10g, imp
Hi,
We are trying to restore a schema by running >imp. We are pretty sure that the dump file is ok.
We get the error
IMP-00>01: dump file "path/expdat.dmp" may be an Data Pump export dump file <imp-0000: Import terminated unsuccessfully
Any ideas?
Many thanks
CamillaDear Camilla,
Please check if you user impdp instead of imp command!
Regards,
Reza -
Getting error imp-00017 while tryimg to import dump
HI,
My imp command is
USERID= sqapkob/sqapkob@orcl2
FILE=/export/home/fccus/DUMP/fcpkob2.dmp
LOG=/export/home/fccus/DUMP/fcpkobexpl.log
FROMUSER=FCPKOB
TOUSER=SQAPKOB
IGNORE=Y
FEEDBACK=200
COMMIT=Y
Rows=Y
I am getting errors like
imp-00017following statement failed with oracle error 2304
create type "TY_IFXML_DATA" TIMESTAMP '2008-03-06' oud '2EE4949FE1' please help me about this and i am new to oracleFollow the instructions from this metalink note:
IMP-17 IMP-3 ORA-2304 IMP-63 FROMUSER/TOUSER Import of Table With Object Column
Doc ID: Note:1066139.6
Werner -
EXP from UNIX to IMP in windows.
I have an export from UNIX of oracle 10.2.0.1.
I have taken backup with EXP utility of oracle.
I need to import that DUMP into windows with IMP command.
Is that possible?
Will it be successful?
Thank,To open, view, unzip, decompress or uncompress a Gzip compressed archive file in Windows environment, a third party compression and decompression utiltiy or file archiver or data compression utility that supports Gzip archive file format is needed.
You should unzip, then transwer it to Windows to use it
Kamran Agayev A. (10g OCP)
http://kamranagayev.wordpress.com -
IMP-00017: following statement failed with ORACLE error 1849
Hi
We have a instance 11.1.0.7
while doing import i got the issue as:
IMP-00017: following statement failed with ORACLE error 1849:
"BEGIN "
"dbms_scheduler.create_job('"MAXIMOTSSYNC"',"
"job_type=>'STORED_PROCEDURE', job_action=>"
"'maximo_ts_job'"
", number_of_arguments=>0,"
"start_date=>'30-AUG-12 15.12.04.000000 +04:00', repeat_interval=> "
"'SYSDATE + 5/1440'"
", end_date=>NULL,"
"job_class=>'"DEFAULT_JOB_CLASS"', enabled=>FALSE, auto_drop=>TRUE,comments="
">"
"NULL"
"dbms_scheduler.enable('"MAXIMOTSSYNC"');"
"COMMIT; END;"
IMP-00003: ORACLE error 1849 encountered
ORA-01849: hour must be between 1 and 12
ORA-06512: at line 2
IMP-00091: Above error occurred on the following function and object: CREATE MAXIMOTSSYNC. Remaining PL/SQL blocks for this object will be skipped.
Import terminated successfully with warnings.
My imp command is:
imp system/manager file=schema.DMP log=schema.log fromuser=max touser=max
Please suggest on this
Thanks
ShaikORA-01849: hour must be between 1 and 12Error: ORA 1849
Text: hour must be between 1 and 12
Cause: An invalid hour was specified for a date using the 12-hour time format.
If a 12-hour format code (HH or HH12) is used, the specified hour must
be between 1 and 12.
Action: Enter an hour value between 1 and 12. -
Hi,
in 8.1.7 I want importe a table then I have this error :
import done in WE8DEC character set and WE8DEC NCHAR character set^C
IMP-00017: following statement failed with ORACLE error 1012:
"CREATE TABLE "TRAILOCC" ("TO_REF" NUMBER(12, 0), "TO_ENTITY" CHAR(40), "TO_"
"DATE" DATE, "TO_TIME" DATE, "TO_OCC" LONG) PCTFREE 10 PCTUSED 40 INITRANS "
"1 MAXTRANS 255 NOLOGGING STORAGE(INITIAL 723025920 FREELISTS 1 FREELIST GRO"
"UPS 1) TABLESPACE "PROD_DATA""
Can I then create this table TRAILOCC with INITIAL 223025920 and then importe the table ?
What should I add in imp command to importe just data since table is already created ?
Many thankshi
cmd> imp ignore=y
hope this helps
Tajcheck the prod_data tablespace has enough space -
Hi,
I launched imp to importe a table, actually enough rows are imported but in commande box of win2000pro where I issued imp commande , it does not go on and stopped on
import table xxxx
how can I stop import ?
Just ctrl+c, or kill, or something else ? What ?
Many thanks before.
PS : DB 9.2.0 on a windows 2000 sp3You can also stop the import by killing the Oracle session.
alter system kill session '<sid>, <serial#>';
You can find the sid and serail# from v$session. -
Exp/Imp In Oracle 10g client
Hi All,
I want to take one schema export from Oracle 10g Client. I am in new Oracle 10g.
In oracle 9i, we can using exp/imp command for Export and Import from Client itself.
I heard about in Oracle 10g, we can use Expdb/Impdb in Server only. Is there any possibility to take exp/imp in Client also.
Pls help me...
Cheers,
Moorthy.GSTo add up to expdb from oracle client
NETWORK_LINK
Default: none
Purpose
Enables an export from a (source) database identified by a valid database link. The data from the source database instance is written to a dump file set on the connected database instance.
Syntax and Description
NETWORK_LINK=source_database_link
The NETWORK_LINK parameter initiates an export using a database link. This means that the system to which the expdp client is connected contacts the source database referenced by the source_database_link, retrieves data from it, and writes the data to a dump file set back on the connected system.
The source_database_link provided must be the name of a database link to an available database. If the database on that instance does not already have a database link, you or your DBA must create one. For more information about the CREATE DATABASE LINK statement, see Oracle Database SQL Reference.
If the source database is read-only, then the user on the source database must have a locally managed tablespace assigned as the default temporary tablespace. Otherwise, the job will fail. For further details about this, see the information about creating locally managed temporary tablespaces in the Oracle Database Administrator's Guide.
Restrictions
When the NETWORK_LINK parameter is used in conjunction with the TABLES parameter, only whole tables can be exported (not partitions of tables).
The only types of database links supported by Data Pump Export are: public, fixed-user, and connected-user. Current-user database links are not supported.
Example
The following is an example of using the NETWORK_LINK parameter. The source_database_link would be replaced with the name of a valid database link that must already exist.
expdp hr/hr DIRECTORY=dpump_dir1 NETWORK_LINK=source_database_linkDUMPFILE=network_export.dmp LOGFILE=network_export.log
Maybe you are looking for
-
MacPro Quad Core 32g Ram running slow Logic using only 9g in Activity Monitor
Well its taken a while, but this is my first foray into the world of forums! I'm so hacked off with this regular problem and havent been able to find anything anywhere to solve it i thought i'd see if anyone has any similiar issues and maybe even a s
-
How to restore your restriction passcode on an ipad
how to restore your Restriction passcode on an ipad?
-
Hello, Is anyone aware of wheather Biller Direct provide functionality of scheduling of payment(future date)? Thanks in advance! Regards, Ricky
-
What's puzzling me is how similar win7 is to Vista_Ultimate
once safari has been installed into tha body, webkit2webprocess.exe's dumped into tha core. This is tha end_result to a goal that's more f'd up! There are person's of interest that own a mac_book and have experienced similar problems on their respec
-
Howto call custom Oracel Data Type with TopLink?
Hello, in our DB we have a custom Oracle type and a PL/SQL method which uses it. I would like to call the Oracle data type with TopLink. How can I do this? I could not find any documentation on this. I know JPublisher can do this but I don't want to