Sqlplus Copy Command
Feb 15, 2013
i am trying to copy the data from a remote database which has Oracle 8i thru Sqlplus copy command to the local database which has Oracle 11gR2.
copy from abc/abc@remote
insert emp_new
using
select *
from emp_old
where rownum < 1001;
is it possible to copy the remote database thru sqlplus copy command ?
View 6 Replies
ADVERTISEMENT
Jul 29, 2012
I am using the SQL*PLUS COPY command to move the data from my database to another remote database. The data in my database also contains DATETIME format. But since COPY command cannot handle DATETIME format, I am wondering is there any workaround for this.
Note: Due to some limitations, I cannot use other methods like DATABASE LINK or EXPDP/IMPDP commands.
View 12 Replies
View Related
May 3, 2013
I have two identical tables from different DB's and I need to copy a row from db1 and insert into db2 if it does not exist or update it if it does(on the tables pk).
This is what i was trying until i realized replace drops the whole table where i thought it dropped the row and inserted the new.
copy
from db1
to db2
replace table2
using
select *
from table1
where x = blah
View 3 Replies
View Related
Feb 18, 2013
I have some Oracle Databases and sometimes for me is easier to access to the databases with SQLPLUS instead SQLDEVELOPER or TOAD.
But i can't reach to a good configuration of command line prompt to do queries against the database, normaly if it returns a lot o rows and columns it is unreadable.
View 5 Replies
View Related
Feb 19, 2008
how to run dos command from sql prompt.
i.e.
SQL>!DIR
Same can be done in unix using ! character.
SQL>!ls -lrt
View 6 Replies
View Related
Feb 22, 2010
I got to pull 30M data into local DB from a remote DB. As of now we have procedure to perform this task using an
Insert /*+append*/ table1
select *
from rdb_view;
I observed using the copy command in sql plus has taken very less time than the procedure.Can we use the Copy command inside the PL/SQL block? I tried with dynamic SQL but It is not allowed I guess.
View 16 Replies
View Related
Jul 25, 2012
In my sql*plus when i am writing the command ed .It was showing the error as \
SQL> ed
SP2-0110: Cannot create save file "afiedt.buf"
i tried to define the editor by using the command define_editor=notepad;
But still my problem was not solved.
View 2 Replies
View Related
Aug 28, 2012
I am trying to execute the SQLPLUS command (CONNECT) from the stored procedure.It is throwing below error message.
Stored Procedure:
SQL> select user from dual
2 ;
USER
------------------------------
SYS
SQL> create or replace
2 PROCEDURE PROCEDURE1 AS
3 BEGIN
4 sqlplus sys/sys@D as sysdba;
5 --execute immediate 'create user 'kkk' identified by 'kkk';
6 END PROCEDURE1;
7 /
Warning: Procedure created with compilation errors.
SQL> show err
Errors for PROCEDURE PROCEDURE1:
LINE/COL ERROR
-------- -----------------------------------------------------------------
3/9 PLS-00103: Encountered the symbol "SYS" when expecting one of the
following:
:= . ( @ % ;
The symbol ":=" was substituted for "SYS" to continue.
[code]....
View 29 Replies
View Related
Jul 31, 2013
I need to parse .sql file to tree and I can't find how to do it.
(We apply sql files by sqlplus and we have some problems with '/': after anonymous blocks - it haven't applied without '/'; Also not-anonymous block applied twice when we have both ';' and '/'. I need to report about problems before file will apply.) I've tried to use ANTLR with it grammar but it build awful tree.
View 5 Replies
View Related
Jan 21, 2011
I am able to start SQLPLUS from Start | Program files | Oracle - OraHome92 | Application development |
Unfortunately, when trying to start it from the "command prompt" window with the following command SQLPLUS, it generates the infamous error message like
"... unknown etc... "
Any variables i need to change on my client machine ?
View 11 Replies
View Related
Jul 21, 2010
I'm trying to change a password. I can connect to the db then at the SQL prompt I'm using:
alter user <name> identified by <new password>
The dos window comes back with '2' - then just sits there
View 4 Replies
View Related
Mar 5, 2011
tried installing oracle 10g in ubuntu. i am successful with the oracle installation.i am able to login to sqlplus using oracle OEM,but when i try to login through command prompt , i get the following error:
rakesh@ubuntu:/$ sqlplus "/ as sysdba"
bash: sqlplus: command not found
[color="#000000"][/color]
rakesh@ubuntu:/$ sqlplus
bash: sqlplus: command not found
i have also tried to set the oracle_home, oracle path & oracle SID.
find the below configuration parameters which i have set to.
root@ubuntu:/usr/lib/oracle/xe/app/oracle/product/10.2.0/server/bin# more oracle_env.sh
ORACLE_HOME=/usr/lib/oracle/xe/app/oracle/product/10.2.0/server
export ORACLE_HOME
ORACLE_SID=XE
export ORACLE_SID
#NLS_LANG=`$ORACLE_HOME/bin/nls_lang.sh`
[code]....
View 4 Replies
View Related
Oct 3, 2013
I am using the HOST command within Oracle Forms 10g on Windows server to copy a pdf file from the application server to a network folder on another Windows server.
The command works fine if I logon to Windows app server and type it. But it doesn't work when it is launched within Oracle forms using HOST. The command looks as follow
net use \\FileServer\e-file /user:usergroup\username password & copy D:\RepTmp\myReport.pdf \\FileServer\e-file\test\myReport.pdf
Oracle forms doesn't give any error message at all but the pdf file never gets there. Even when I map the network folder as "R:" drive on the Windows app server, a simple copy command like this does not work with HOST:
copy D:\RepTmp\myReport.pdf r:\test\myReport.pdf
Oracle Forms server is running as "SYSTEM" on the Windows server. If HOST won't work, is there any other way to copy the file other than using fpt?
View 1 Replies
View Related
Sep 6, 2010
The way to create a short cut on desktop to have an sql*plus (command line).
i.e. I want to have an short cut on desktop when I click that short cut that would connect me to a specific database with a username and password (which i supply while creating the shortcut-I would provide the database name, username and password)
View 7 Replies
View Related
May 11, 2012
When i try to copy a table within the database i get insufficient priv error.
SQL> COPY FROM JACK@JACK -
> CREATE T -
> USING SELECT * FROM JACK.T;
Enter FROM password:
Array fetch/bind size is 15. (arraysize is 15)
Will commit when done. (copycommit is 0)
Maximum long size is 80. (long is 80)
ERROR:
ORA-01031: insufficient privileges
what privilege is required to perform this copy command ?
View 2 Replies
View Related
Jun 23, 2010
I am facing one problem we used to copy any document and for open any document in WINDOWS
Host('CMD /C COPY '||'"'||:Old_Doc||'"'||' X:�3�3'||:New_Doc);
Client_Host('Cmd /C Start '||'X:�3�3'||:New_Doc);
But these commands not running in Linux.
View 12 Replies
View Related
Sep 13, 2013
we are running SAP application against oracle database. say, if I use brspace or brtools (from SAP side) to shutdown or startup database or collect stats, does this mean it not recommend to use oracle command to shutdown/start & collect stats?
View 3 Replies
View Related
Apr 22, 2008
I'm having some minor trouble with my sqlplus in Windows. Don't know which feature I accidentally edited by cosole seems to be in debug mode. Everything is ok, except that it print the old and new values of my variables. How can't I restore it to it's original behavior.
View 3 Replies
View Related
Aug 19, 2012
when i enter a sql * plus session an do a rollback; (without performing anything), always a "rollback complete" message appears even if there is nothing to rollback.
View 4 Replies
View Related
Sep 30, 2003
I'm running a C++ program to call sqlplus to execute some sql scirpts. The program will accept arguments from users at the command line, and execute the script which the name will also be passed in as an argument to the program eg:
./MY_PROG.sh ABC.sql 23
(MY_PROG will call ABC.sql script and pass 23 as an argument to ABC.sql)
it works fine when the argument is passed in correctly, and my ABC.sql scirpt is able to execute correctly, however when the argument is not passed in, the program just hangs there, waiting for an input from the users. This is because "&1" in my script is expecting some value from users.
Because this program will be scheduled to run, and no one will be there to monitor the job, if so happens arguments were missing, the program will wait there for the entire night. Is there any way that I could make the program or the script to exit when there is no input to be found? I can't use timeout as I do not know how long does the script take to finish it operations, I could be updating millions of record from a script.
View 2 Replies
View Related
May 16, 2007
We have two database instances on the same server. One was left at 9.2.0.7 and one was upgraded to 10.2.0.3. Connecting externally (sqlplus '/as sysdba') to the 9.2.0.7 database is lightning fast. Connecting externally to the 10.2.0.3 database is very slow, comparatively speakiing. This is on an IBM AIX-5L (64-bit) machine. We are using "tnsnames".
View 10 Replies
View Related
Jul 18, 2013
I'm having issues with users logging into Oracle. I installed it on Ubuntu 12.04 running Oracle 11.2 XE. If i am root, i can run sqlplus just fine and log in. But when I use a regular user account and run sqlplus, it will just stay blank. No error messages or any feedback. I echo $ORACLE_HOME and echo $ORACLE_SID and they come back exactly as they do under the root account. My path is set up just like root has it.
It almost seems like a permission issue but even when i try sqlplus /nolog it stays blank.
[URL]
View 1 Replies
View Related
Aug 3, 2010
I have installed oracle 10g on opensuse. After i logon as normal user and type sqlplus, it was display an error message as below:-
login: nv2am
Password for nv2am:
login: Configuration file does not specify default realm when parsing name nv2am
Last login: Tue Aug 3 16:33:19 from 10.69.20.25
Have a lot of fun...
Directory: /home/nv2am
Tue Aug 3 17:36:23 MYT 2010
nv2am@ARMSDEV:/home/nv2am> sqlplus
-ksh: sqlplus: not found [No such file or directory]
nv2am@ARMSDEV:/home/nv2am> sqlplus "/ as sysdba"
-ksh: sqlplus: not found [No such file or directory]
nv2am@ARMSDEV:/home/nv2am> set ORACLE_SID="ARMSDEV"
nv2am@ARMSDEV:/home/nv2am> svrmgrl
-ksh: svrmgrl: not found [No such file or directory]
nv2am@ARMSDEV:/home/nv2am>
View 1 Replies
View Related
May 14, 2013
I want to add a value from sqlplus.
My scenario is like that i want to add the following value
select count(*) x from tab1
i need to connect several database, and each time i need to add with previous one. like that
connect a/a@db1;
select count(*) x from tab1;
then when i connect another db
connect b/b@db2;
select count(*) x from tab1;
x will add with previous one.
View 6 Replies
View Related
Jul 20, 2011
Here is a simple sqlplus line command with & substitution run time variable.
set verify off;
SQL> SELECT * FROM emp where sal >&SAL;
Enter value for sal:
Now as you see, oracle asks to Enter Value for substitution variable in line just below the SQL>. I wonder if there is one or more line could be left there so to improve the readability. So it should look like:
set verify off;
SQL> SELECT * FROM emp where sal >&SAL;
Enter value for sal:
View 2 Replies
View Related
Apr 29, 2013
how to restrict sqlplus as sysdba
C:> Set Oracle_sid=Mydb
C:>sqlplus / as sysdba
Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0
I don't want to log in any one as sqlplus / as sysdba.If they can able to login as sqlplus / as sysdba then they can see others schema in the database.Say if i set
SQLNET.AUTHENTICATION_SERVICES=none
no one can log in as sysdba were as later some one changes to
SQLNET.AUTHENTICATION_SERVICES=NTS
After they changes to NTS they can log in and access other user details right ? how to restrict
Oracle version: Oracle 11 g
OS Version :Win 7
View 21 Replies
View Related
Aug 29, 2012
My database in on 10.2.0.3 and facing hang problem when I am connecting to sqlplus.
bash-3.00$ sqlplus / as sysdba
SQL*Plus: Release 10.2.0.3.0 - Production on Wed Aug 29 00:54:03 2012
Copyright (c) 1982, 2006, Oracle. All Rights Reserved.
ERROR:
ORA-01075: you are currently logged on
As per Metalink note(215858.1) suggested in forums I have followed steps and produced results below.
bash-3.00$ sqlplus -prelim
SQL*Plus: Release 10.2.0.3.0 - Production on Tue Aug 28 23:28:02 2012
Copyright (c) 1982, 2006, Oracle. All Rights Reserved.
Enter user-name: / as sysdba
SYS on test>oradebug help
SYS on test>oradebug setmypid
Statement processed.
SYS on test>oradebug hanganalyze 12
[code]...
Now I have got struck how to analyze above results.
View 3 Replies
View Related
Sep 7, 2013
"C:UsersKarthikeyan>sqlplus / as sysdba SQL*Plus: Release 12.1.0.1.0 Production on Sat Sep 7 17:42:37 2013 Copyright (c) 1982, 2013, Oracle. All rights reserved. ERROR:ORA-12560: TNS:protocol adapter error Enter user-name:"
this is the first time i tried to open sql*plus and i didn't create any database connection before....so i don't have any username and password.......
View 20 Replies
View Related
May 29, 2013
running CENTOS 6 and oracle DB 11.2.0 and when i try to launch sqlplus i get the following error:
Error 6 initializing SQL*Plus
SP2-0667: Message file sp1<lang>.msb not found
SP2-0750: You may need to set ORACLE_HOME to your Oracle software directory
problem is, it's telling me to set ORACLE_HOME but I'm not sure where this is to set.
View 17 Replies
View Related
Mar 25, 2009
I'm trying to create a new table which has a date field (date of birth) and I want to include a constraint which will not allow me to add values if they are over 21 years old. I'm using SQLPlus .
View 3 Replies
View Related