SQL *PLUS issue
I have an unusual problem in SQL PLUS. When the SQL statement is a DML things go fine - no problem, BUT when the SQL statement is a DDL (like creating a database object )the process hangs. Things get more interesting ... if I open another SQL PLUS session and check out, I find that the DDL has done its task. But the first SQL session (where I issued the DDL) is still hanging. If anyone has any idea please do let me know. Any help would be very useful
Thanks
Mustafa
The dot is used as like concatenation operator in sqlplus. If you need to add characters to the end of the variabel, you use a dot. If you need to add .chars then you need two dots.
With a dot
SQL> SELECT 'Say &something.not' FROM dual;
Enter value for something: something
old 1: SELECT 'Say &something.not' FROM dual
new 1: SELECT 'Say somethingnot' FROM dual
'SAYSOMETHINGNOT
Say somethingnotand without
SQL> SELECT 'Say &somethingnot' FROM dual;
Enter value for somethingnot: something
old 1: SELECT 'Say &somethingnot' FROM dual
new 1: SELECT 'Say something' FROM dual
'SAYSOMETHING
Say somethingTTFN
John
Similar Messages
-
Folks,
Hello. My Operating System is Oracle Linux 5. Database is Oracle DB 11gR1.
I have tried to set up SQL*Plus in the following way:
My directory: /home/myOracle/OracleDB_Home/bin
SYSTEM_PASS=SYSTEM/SYSTEM
export SYSTEM_PASS
./sqlplus SYSTEM/SYSTEM
But this message comes up:
Error 6 initializing SQL*Plus
Message file sql<lang>.msb not found
SP2-0750: You may need to set ORACLE_HOME to your Oracle Software directory.
Where is message file sql<lang>.msb ? What is Oracle Software directory ?
Can any folk help to solve this issue ?Duplicate post
Re: Set Up SQL*Plus Issue -
Not entirely sure if I've posted in the correct area..
I've recently installed the Oracle 11g. Installation process seemed fine but I'm unable to access any components of the software (eg. SQL Plus)
When I try to enter my UN and PW, I keep getting the ORA-01017: INVALID USERNAME/PASSWORD: LOGON DENIED.
If I'm not mistaken, isn't this meant to be the default username and password set during the installation process? (un in this case was orcl, and I set my own password supposedly)
I've installed it on my home computer so, I'm not aware of any dba or what not ;S
OS: Windows 7 Ultimate
Please let me know of any more information you require. Thanks!
On a side note, I also cannot access the SQL Developer- says it cannot find the path to java.exe. I have installed the JDK 7 and written the path down but still does not work. Help with this is also appreciated but, the SQL Plus issue is predominant ;x
Edited by: 992341 on Mar 6, 2013 8:13 PM992341 wrote:
Not entirely sure if I've posted in the correct area..
I've recently installed the Oracle 11g. Installation process seemed fine but I'm unable to access any components of the software (eg. SQL Plus)
When I try to enter my UN and PW, I keep getting the ORA-01017: INVALID USERNAME/PASSWORD: LOGON DENIED.
Believe this & EVERY Oracle error code & message.
BTW - With V11 passwords are CaseSenSitive; "FUBAR" is different from "fubar", etc.
I am curious regarding to which USERNAME are you trying to login as?
If I'm not mistaken, isn't this meant to be the default username and password set during the installation process? (un in this case was orcl, and I set my own password supposedly)
I've installed it on my home computer so, I'm not aware of any dba or what not ;S
OS: Windows 7 Ultimate
Please let me know of any more information you require. Thanks!
On a side note, I also cannot access the SQL Developer- says it cannot find the path to java.exe. I have installed the JDK 7 and written the path down but still does not work. Help with this is also appreciated but, the SQL Plus issue is predominant ;x
Edited by: 992341 on Mar 6, 2013 8:13 PMHow do I ask a question on the forums?
SQL and PL/SQL FAQ -
Access database issue in SQL Plus
Hi Friends,
I download a oracle 10g to install sql Plus without create database. (I download client and does not find SQL Plus)
I can ping database server from client PC and also set up a TNS.
However I got a error ORA 12504 --TNS:listener was not start.
I can access database by sql plua from server side. I do not think we need to put a listener file in client PC under admin path.
my database set as RAC module and system as window 2003
how to fix this issue?
Thanks,
JImOK, just to be clear, you have a single client machine where you have installed something with the 10g label. Are you saying that you installed the Oracle database bits, but did not create a database? Rather than doing a client-only install? Is there a single Oracle home on the client machine?
And then you have a RAC database running on multiple Windows 2003 servers, right? Is there a listener running for this RAC database? Can you connect to it from other client machines?
Are you certain that the service name you specified in the client machine's tnsnames.ora file matches the service the listener is listening for?
Justin -
Issue with Taiwanese characters display in SQL*Plus/Toad
Hi all,
I have an issue about displaying the Taiwanese characters either in SQl*Plus or Toad tool. Able to view all territory characters properly except it. Whenever i tried to view these characters from Toad, diplay like square box('⃞'), where as it displays as question mark ('?') from SQL*Plus.
I am not sure what are the parameters i want to alter. Please have a look at the below existed database parameters in the DB and help me to get rid of the issue.
PARAMETER VALUE
NLS_LANGUAGE AMERICAN
NLS_TERRITORY AMERICA
NLS_CURRENCY $
NLS_ISO_CURRENCY AMERICA
NLS_NUMERIC_CHARACTERS .,
NLS_CHARACTERSET AL32UTF8
NLS_CALENDAR GREGORIAN
NLS_DATE_FORMAT DD-MON-RR
NLS_DATE_LANGUAGE AMERICAN
NLS_SORT BINARY
NLS_TIME_FORMAT HH.MI.SSXFF AM
NLS_TIMESTAMP_FORMAT DD-MON-RR HH.MI.SSXFF AM
NLS_TIME_TZ_FORMAT HH.MI.SSXFF AM TZR
NLS_TIMESTAMP_TZ_FORMAT DD-MON-RR HH.MI.SSXFF AM TZR
NLS_DUAL_CURRENCY $
NLS_COMP BINARY
NLS_LENGTH_SEMANTICS BYTE
NLS_NCHAR_CONV_EXCP FALSE
NLS_NCHAR_CHARACTERSET AL16UTF16
NLS_RDBMS_VERSION 10.2.0.4.0
Oracle DB banner:
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bi
PL/SQL Release 10.2.0.4.0 - Production
CORE 10.2.0.4.0 Production
TNS for IBM/AIX RISC System/6000: Version 10.2.0.4.0 - Productio
NLSRTL Version 10.2.0.4.0 - Production
Your help would be appreciated!!
Thanks in advance.
vissuvissu wrote:
Hi all,
I have an issue about displaying the Taiwanese characters either in SQl*Plus or Toad tool. Able to view all territory characters properly except it. Whenever i tried to view these characters from Toad, diplay like square box('⃞'), where as it displays as question mark ('?') from SQL*Plus.
I am not sure what are the parameters i want to alter. Please have a look at the below existed database parameters in the DB and help me to get rid of the issue.
PARAMETER VALUE
NLS_LANGUAGE AMERICAN
NLS_TERRITORY AMERICA
NLS_CURRENCY $
NLS_ISO_CURRENCY AMERICA
NLS_NUMERIC_CHARACTERS .,
NLS_CHARACTERSET AL32UTF8
NLS_CALENDAR GREGORIAN
NLS_DATE_FORMAT DD-MON-RR
NLS_DATE_LANGUAGE AMERICAN
NLS_SORT BINARY
NLS_TIME_FORMAT HH.MI.SSXFF AM
NLS_TIMESTAMP_FORMAT DD-MON-RR HH.MI.SSXFF AM
NLS_TIME_TZ_FORMAT HH.MI.SSXFF AM TZR
NLS_TIMESTAMP_TZ_FORMAT DD-MON-RR HH.MI.SSXFF AM TZR
NLS_DUAL_CURRENCY $
NLS_COMP BINARY
NLS_LENGTH_SEMANTICS BYTE
NLS_NCHAR_CONV_EXCP FALSE
NLS_NCHAR_CHARACTERSET AL16UTF16
NLS_RDBMS_VERSION 10.2.0.4.0
Oracle DB banner:
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bi
PL/SQL Release 10.2.0.4.0 - Production
CORE 10.2.0.4.0 Production
TNS for IBM/AIX RISC System/6000: Version 10.2.0.4.0 - Productio
NLSRTL Version 10.2.0.4.0 - Production
Your help would be appreciated!!
Thanks in advance.
vissuHow was this data loaded into the database ? If SQL Developer is showing incorrect data, then the data was not loaded correctly into the database and has been corrupted - in such a case, NLS_LANG will not help
Srini -
How to connect to SQL*Plus and issue a query all in one command?
Hi everyone,
Does anyone know of a way to connect to a db with SQL*Plus, and issue a simple query, all with one command?
I know that I can save a .sql script with a query, then do this:
sqlplus user/pwd@db @myscript.sql
But I'm wondering if there's any way to put the actual query right into the connect command, something like:
sqlplus user/pwd@db "select count(*) from dba_tables;"
Does anyone know of a way to do this?you didn't mention windows or unix. so, here's a link with both
Re: windows sql script
it also has a link to another thread on how to deal with the parens when using ehco in dos. -
ASM Auto Start vs SQL*Plus Contention Issue
We are trying to install the single server instance of ASM with the Grid Infrastructure and DB 11gR2. We have specified auto start on the oracleasm configuration.
OS = Linux 5.
After a reboot. the ASM processes show up when I run "ps -ef|grep asm". When I log into SQL*Plus it says it's connected to an idle instance. However, when I issue the startup command it responds with "ORA-15149: another ASM instance found running on the host".
My ORACLE_SID = +ASM and my ORACLE_HOME is set to the directory where grid is installed. These are the values that I specified during the Universal Installer session.
Can someone help me make sense of this?
Thanks,
GregoryThanks for your replies.
It turns out that the problem had to do with how I specified the grid ORACLE_HOME. I still don't understand why it should make a difference, but...
I am in the habit of typing a few characters of a directory or file name and hitting tab to have the system fill in the rest of the name. As the system finishes a name it appends a slash. So, I would end up with something like
export ORACLE_HOME=/LIB_ORACLE/11.2.0/grid/That trailing slash was screwing things up. If I entered all of that without the trailing slash, my sqlplus connected just fine.
Thanks again,
Gregory -
How to issue a SQL*Plus command from PL/SQL program?
Thanks.
You can't issue a SQL*PLus command from a PL/SQL program. If you can tell us more about what you are trying to do, perhaps we can offer a substitute.
-
Issue with new line when manually executing a procedure in SQL*Plus
The below procedure works fine in SQL*Plus when the entire EXEC <procedure_name> (parameter1, parameter2, ..); is put in a single line
SQL > exec cust_admin_util.create_schema (P_SCHEMA_NAME => 'SCOTT_01', P_SCHEMA_PWD => 'scott123', P_TBS_NAME => 'TRAG_TBS', p_temptbs_name => 'TEMP' );
PL/SQL procedure successfully completed.I wanted to execute the same procedure with more readability. So, I put each parameters on a separate line and try to execute. But it is erroring out.
SQL > exec cust_admin_util.create_schema
P_SCHEMA_NAME => 'TESTUSR_01',
P_SCHEMA_PWD => 'scott123',
P_TBS_NAME => 'TRAG_TBS',
p_temptbs_name => 'TEMP'
);BEGIN cust_admin_util.create_schema; END;
ERROR at line 1:
ORA-06550: line 1, column 7:
PLS-00306: wrong number or types of arguments in call to 'CREATE_SCHEMA'
ORA-06550: line 1, column 7:
PL/SQL: Statement ignored
SQL > 2 3 4 5 6 7
P_SCHEMA_NAME => 'TESTUSR_01',
ERROR at line 2:
ORA-00928: missing SELECT keywordAny workaround for this ?Hi Tom,
At SQL Plus,
You have to use the -(Hyphen) as the concatenation Operator.
For Instance,
SQL> exec host_command( -
p_command => 'dir');
PL/SQL procedure successfully completed.
Thanks,
Shankar -
Issues trying to Access SQL Plus after downloading 8i Trial Version
After successfully downloading Oracle 8i Personal Edition, I am trying to access SQL Plus, it requires to enter a User Name, Password and Host String. I enter my OTN Password ID and I am refused access. Does anyone have any ideas why?
harry,
i am assuming you are using 6.0.8.8 of reports6i, which is base-release. there have been problems withthe OCA in this version. by using the latest patch you should solve this problem. for further details, please contact oracle support services.
regards,
the oracle reports team -
ShutDown Issue while log in Sql plus
when i log in Sql plus with username and password. it says Oracle Intialization or shutdown in progress.let me know please .
when i go to Application Development -> sql plus -> and when i type username sys as sysdba .and type require password.window close automatically . but when i type username and press ok .button it ask for password .and it working fine .let me know please . any help would be highly appreciated.
Edited by: user1095036 on Sep 2, 2012 2:33 PM -
Please assist...when i am trying to login following error is occuring ....
Enter user-name: / as sysdba
ERROR:
ORA-01031: Message 1031 not found; No message file for product=RDBMS,
facility=ORAMaran thanks for the prompts replies, i have already set the variables & restarted the machine but there is no change. please see below;
C:\Documents and Settings\Administrator>sqlplus
Error 6 initializing SQL*Plus
Message file sp1<lang>.msb not found
SP2-0750: You may need to set ORACLE_HOME to your Oracle software directory
C:\Documents and Settings\Administrator>d:
D:\>cd oracle
D:\oracle>cd ora92
D:\oracle\ora92>cd bin
D:\oracle\ora92\bin>sqlplus
SQL*Plus: Release 9.2.0.6.0 - Production on Fri May 11 17:31:09 2007
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
Enter user-name: / as sysdba
ERROR:
ORA-01031: Message 1031 not found; No message file for product=RDBMS,
facility=ORA -
Issues passing XML to SQL*Plus in UNIX
Oracle 10.2.0.3.0
For some reason I can't seem to figure this out.
This is my PL/SQL script (load_table.sql):
SET SERVEROUTPUT ON
SET VERIFY OFF
DECLARE
v_clob CLOB;
BEGIN
v_clob := '&1';
INSERT INTO rh_page (pageid, pagecontent)
VALUES ('&2', XMLTYPE(v_clob));
COMMIT;
END;
EXIT;
It is executed by this shell script (load_table.sh):
#!/usr/bin/ksh
. $HOME/envfile
USERID=myUserID/myPassword
XMLDATA=`cat test_file.xml`
FILENAME="TestFile"
LOG_FILE=load_table.log
sqlplus $USERID << EOF > ${LOG_FILE}
@ load_table.sql ${XMLDATA} ${FILENAME}
exit 0
Here is a sample of the XML:
<?xml version="1.0" encoding="utf-8" ?>
<Page>
<PageName></PageName>
<Title></Title>
<Roles>-1</Roles>
<Controls>
<PageTool>
<visible>false</visible>
</PageTool>
<divTopLeft>
<visible>true</visible>
</Page>
After I execute load_table.sh, I see that load_table.log contains the following error:
SQL> SQL> DECLARE
ERROR at line 1:
ORA-31011: XML parsing failed
ORA-19202: Error occurred in XML processing
LPX-00007: unexpected end-of-file encountered
ORA-06512: at "SYS.XMLTYPE", line 254
ORA-06512: at line 1
ORA-06512: at line 9Any ideas on what is causing this error or how to resolve?I understand this is probably not the best approach; however, I was in the process of automating the process of reading multiple XML files and loading their content to a table. Since I don't have DB privelges to set up External Tables or utilize UTL_FILE, I was trying this approach to simply direct the contents of an XML file into a UNIX shell script variable, and then pass it on as a SQL*Plus substitution variable.
I originally did this manually, by opening each of the 40+ files and copying/pasting their content to set a CLOB variable in a PL/SQL block...now I'm just trying to figure a way to automate the same manual steps. -
SQL * PLUS formatting issue
Hi, Could anyone please tell me how to BREAK on multiple columns in SQL * PLUS.
create table test (a number, b number, c number);
insert into test values(1,2,5);
insert into test values(1,3,5);
insert into test values(2,2,6);
insert into test values(2,3,6);
Before formatting
=============
SQL> select * from test order by 1,3;
A B C
1 2 1
1 3 1
2 3 2
2 3 2
After formatting the result should be
=========================
A B C
1 2 1
3
2 3 2
3
That means break on A,C and skip first record.
I tried using "break on A,C skip 1", but its not working.
Using SQL * PLUS to fire this formatting.
Thanks.break on A,C and skip first record.
I tried using "break on A,C skip 1", but its not working.
Using SQL * PLUS to fire this formatting.
Just one advice for you: RTFM
SQL>
SQL> desc test
Name Null? Type
A NUMBER
B NUMBER
C NUMBER
SQL>
SQL> select * from test order by 1, 3;
A B C
1 2 5
1 3 5
2 2 6
2 3 6
4 rows selected.
SQL>
SQL> break on a on c skip 1
SQL>
SQL> select * from test order by 1, 3;
A B C
1 2 5
3
2 2 6
3
4 rows selected.
SQL>
SQL>Note that, in your post, the results of your SELECT statement do not match the data inserted by your INSERT statement.
pratz -
Please Help with Forms and SQL Plus Connection Issues in XE
I am not able to connect with the Forms Builder or SQL Plus with the following errors:
When attempting to connect with the supplied website.edu:port/orcl
ORA-06401: NETCMN: invalid driver designator
When leaving the connection information blank and using my local login and password
for my copy of Oracle XE
ORA-12560: TNS:protocol adapter error
Based on some reading, I set the TNS_ADMIN user environmental variable, trying each of the tnsnames.ora locations but I'm still receiving the same errors
Location 1: DevSuiteHome\...\tnsnames.ora
Location 2: oraclexe\...\tnsnames.oraThanks, Vikas!
But I did a search for 6iServer.conf and did NOT locate any such file
Please help
TIA
SHANKAR
Shankar,
It would have helped if you had indicated what is the full version of 9iAS that you have installed. By default the portnumber that is used is 7778.
As per the entries, they should have already been made in the config files. But check that the 6iServer.Conf file and it should contain the entries that you are being told to update. If not, then add the entries in the 6iServer.conf file and that is all you need.
HTH.
Vikash
Maybe you are looking for
-
Imac intel 24 inch overheating
Why is my imac overheating when the computer has been on for a couple of hours?
-
IBook G4 not recognizing external drive
I have an iBook G4 w/OS10.3.9. Up until the past couple of days, I have been able to regularly backup my internal drive to both my Iomega and Maxtor USB drives. Now when I connect them, I either get a message indicating that they are not readable and
-
The Strange Case of the Disappearing Site
It's one thing after another all of a sudden. I've just opened iWeb on my desktop and found that the entire site is no longer there. This happened once before, a few months ago, and (following excellent advice on this discussion board) I clicked Spot
-
HELP Creating Connections in the ABAP and JAVA Environments
Hi good morning, I have a problem and I would like your help. I'm new at Abap and I'm trying to develop an application from ABAP to connect to an environment of java. I watched how to do this in various forums and the help of SAP, but just as I have
-
Hi, am using Imac with firefox and safari. When i try and connect to facebook or apple.com error comes up "Host unresolved". Every other website opens normally. happens with both safari and firefox. Any ideas?