Questions tagged [sqlplus]

Command-Line Utility Program for Oracle

Filter by
Sorted by
Tagged with
1
vote
3answers
5k views

System account locked, insufficient privileges to log in as sysdba

I've researched the web but I could not found exactly the same situation than mine so I'm posting this message. I'm connecting via Remote Desktop Connection to a remote server (Win2k3 Server). This ...
2
votes
2answers
1k views

Empty v$asm_diskgroup with sqlplus

I have an Oracle Database instance installed under an OL7. It is a 12c2. Oracle GI also installed and my database has some files stored in ASM. I am using sqlplus to connect to the database instance ...
0
votes
1answer
1k views

Oracle: Save PDB state for all instances in RAC environment

I found out the following two contradicting statements in the Oracle DBA guide. For an Oracle RAC CDB, you can use the instances clause in the pdb_save_or_discard_state clause to specify the ...
0
votes
1answer
100 views

Difference between init.ora db_name and query in sqlplus

I have a question about the content of the file init.ora, according to oracle documentation. DB_NAME specifies a database identifier of up to 8 characters. This parameter must be specified and must ...
0
votes
2answers
10k views

Oracle: spool data to different files depending on where condition (loop)

I am trying to get my way around something like this declare filename varchar2(100); begin for condition in (select fieldN from mytable) loop filename := 'data_for_value'||condition.fieldN||'...
-1
votes
1answer
966 views

Create new control files using SQLPLUS

down vote favorite I need help with creating controlfile using sqlplus. I have used next steps, I altered spfile, shutdown database, startup nomount, used next command to create controlfile but it ...
0
votes
1answer
40 views

How to add table to database inventory in sqlplus oracle 12c

Problems How to create database Inventory database and inside it table Items in sqlplus oracle 12c . Details Im beginner on Oracle 12c release i setup oracle and i create database Inventory Now ...
0
votes
1answer
136 views

How to use SQL*plus from standard user in Windows Vista to run sql query to Oracle10g on my server?

i have a bach file it contain: @echo off sqlplus x/y@z @run.sql for execute this code correctly i have to execute this file from administrator user from my client, for some reason i need to run ...
1
vote
2answers
2k views

Spool Unicode data in sqlplus to ISO-client without character set conversion

I'm currently facing the following problem: We have an Oracle 11g database with character set AL32UTF8, and an sqlplus-client with NLS_LANG=GERMAN_GERMANY.WE8ISO8859P1. Stored in the database are ...
2
votes
1answer
5k views

How to install Oracle sqlplus, rman utilities on local Windows workstation?

I am the administrator for our organization's Oracle database. I would like to install sqlplus and rman client utilities on my local workstation so I can administer the database without having to ...
0
votes
2answers
49 views

Column names display issue in terminal

I am using SQL*Plus and connected to the HR schema. When I do SELECT * FROM tab; it gave me three column names displayed in different lines. Is there a way to correct it?
0
votes
1answer
309 views

limiting db user password to 3 days

Can any one help me with this query? I want to change expiry date for db user to 3 days from current date, but I am not getting the query for the same. I have installed Oracle Express 11g, it is ...
1
vote
1answer
2k views

SQL*Plus TNS:protocol adapter error [closed]

I am using this system on which everything was already configured. I want to connect to local db on SQL Plus. When I enter user-name scott and password tiger, it gives ORA-12560:TNS:protocol adapter ...
0
votes
1answer
214 views

As an application what are differences between sqlplus.exe and sqlplusw.exe?

Currently i am using Oracle 10g and i can use both sqlplus and sqlplusw. But is there any difference in using them. And, is any of the is deprecated in newer versions?
-1
votes
1answer
5k views

sqlplus / as sysdba is not working in windows, ERROR: ORA-12560: TNS:protocol adapter error

I tried to login using sqlplus / as sysdba in Oracle 11g, but it is asking for a password. So I tried to login using sqlplus "/ as sysdba" since I'm using Windows. But it is showing the following ...
1
vote
1answer
5k views

How to preserve sqlplus session in shell script

I am trying to insert queries from a sql file in shell script using sqlplus. Now, some queries can fail because of incorrect schema. So I want to commit all transactions only if all queries succeed. ...
1
vote
1answer
1k views

Login into Oracle Database Error

I had installed Oracle 12 to my Linux box. I tried to login using sqlplus but it prompt out this error at below. How to solve it? Enter user-name: SYSDBA Enter password: ERROR: ORA-01034: ...
0
votes
2answers
836 views

Pass multiples values to script into sqlplus in Oracle

I want to execute the same sql script passing one text every time but I don't know how to it. I want to do it into sqlplus. With this select I have the values but I don't know how to pass this ...
0
votes
1answer
51 views

Confirmation of SQL statement disappeared

Until today after every SQL statement eg. CREATE user t identified by t; I had a confirmation of the execution "User created." Now I have nothing (no confirmation) but if I check if the user exists it ...
-1
votes
1answer
578 views

ORA-01304 not available

I have been getting this error since I tried to the following command: alter system set sga_target = 1512m scope=spfile; I get the following message when I try type any command in sqlplus: SQL> ...
0
votes
1answer
15k views

ORA-14400: inserted partition key does not map to any partition

I try to create table from ORACLE setup script After I run the script SQL> @home/oracle/Desktop/Setup.sql Following output appears: Table dropped. Table created. Index created. INSERT INTO tab1 ...
9
votes
5answers
17k views

“ORA-24454: client host name is not set” when connecting from Ubuntu instance on AWS EC2

Some background: I am attempting to connect to an Oracle database. I have a username, password, IP address, port, and service name. I only have access to this database from an Ubuntu EC2 instance on ...
0
votes
1answer
1k views

How to spool output from SQL*PLUS to appear in single line with 1 space in between them?

I have a table with 20 rows. I want to spool the rows into a text file where rows come side by side in one line and have one space in between to keep them separated. I intend to create a tar.gz file ...
0
votes
0answers
182 views

How to turn on the expanded mode in Oracle SQL*Plus?

As in the switch \x of PostgreSQL. For more information on the PostgreSQL expanded mode, fetch https://serverfault.com/questions/618642/psql-expanded-mode-equivalency-for-mysql. Both PostgreSQL and ...
0
votes
2answers
3k views

ORA-32000: write to SPFILE requested but SPFILE is not modifiable

I'm not able to alter the SORT_AREA_SIZE in my database.
0
votes
3answers
2k views

How to check oracle error description in sqlplus?

I'm trying to find the oracle error's description in SQL*PLUS. Similar command in DB2 as ? SQLXXXX Where XXXX is the error number.
0
votes
1answer
1k views

can not connect to oracle database with ip address

I am new to oracle database, I have installed Oracle 11.g on redhat 5.6, I have a database that I can connect to it using the following command: export ORACLE_SID=test sqlplus user/passwd but not ...
0
votes
1answer
153 views

Why does SQL Developer update Oracle Data Dictionaries while SQL*Plus does not?

I have the following code stored in a script file create or replace package test_record is type t_test_rec is record( name varchar2(64) ,value ...
0
votes
2answers
539 views

How to prompt sql if there is no exception

I'm new to SQL advance methods. I'm trying to do some error handling after checking for exceptions. DECLARE value_invalid exception; BEGIN EXECUTE IMMEDIATE 'ALTER SYSTEM SET sga_max_size=12g'; ...
0
votes
1answer
672 views

Problems connecting remotely to a RAC DB via sqlplus

When I create a user in an 11204 single instance DB and afterwards grant the sysdba privilege to that user I can connect remotely without any problems using: sqlplus testuser/testuserpwd@testdb as ...
1
vote
1answer
17k views

ORA-00201: control file version 12.1.0.2.0 incompatible with ORACLE version 11.2.0.0.0

I'm trying to mount my database but sqlplus returned the following error : SQL> startup ORACLE instance started. Total System Global Area 1073741824 bytes Fixed Size 2932632 ...
1
vote
1answer
50k views

SP2-0667: Message file sp1<lang>.msb not found sqlplus oracle

I've a linux RedHat which contains oracle database. I setted all environnement variables, but when I running sqlplus command I've this error : SP2-0667: Message file sp1<lang>.msb not found ...
2
votes
2answers
4k views

Oracle 12c: Password File Questions

For one of my assignments I have been attempting to demonstrate password file functionality. However, I have run into some unexpected behaviors. I have tried searching around for answers but can't ...
0
votes
2answers
805 views

Create tablespace “error in creating database file, access denied (OS 5)”

I try to create a database file in this location I've checked the route and everything, I've tried several times to create the tablespace like this... ...but as you can see, I was just lead to ...
3
votes
1answer
333 views

Oracle DB Security Issue: Anyone can login using SQL*PLUS, with any username, and any wrong passphrase

I'm using Oracle DB 11g-R2 on CentOS 6.4, and unfortunately there is a terrible issue freaking me out. Anyone can login using SQL*PLUS, with any username, and any wrong passphrase. Consider somebody ...
3
votes
1answer
704 views

ORA-12154: TNS: Could not resolve the connect identifier specified

I am running a script that "creates/replaces" a procedure in a database and then runs the procedure. The code is as below: WHENEVER SQLERROR EXIT UNDEFINE g_cust_pwd UNDEFINE g_db_name SPOOL '...
1
vote
1answer
119 views

I am not able to use the sqlplus after intalling 11g on redhat 6.7 [closed]

When I execute: $ sqlplus / as sysdba bash: sqlplus: command not found and the bash profile for oracle user is : # .bash_profile # Get the aliases and functions if [ -f ~/.bashrc ]; then ....
1
vote
1answer
692 views

How to address ORA-03113?

If I leave sqlplus open and unused for too long (probably 15 minutes or more), when I EXIT the following message will appear. ORA-03113: end-of-file on communication channel Does this indicate a ...
-1
votes
2answers
5k views

Not able to login to oracle using sqlplus utility because username and password contain space

Using oracle SQL Plus command prompt i able to login with user "p 6". for login connect command is used. but i want to login with sqlplus command line utility and using window command prompt. but it ...
2
votes
3answers
25k views

How in Oracle can I export package that will have package and body?

I'm using putty. How in Oracle can I export package and its body to a file in present directory using spool? Thanks
1
vote
2answers
5k views

Compile a PLSQL package code that was passed to an sqlplus session via a shell script?

I have two files: (1) and (2) (1) A Shell script - wrapper.sh #!/bin/sh echo "start of shell script" FILE_NAME="XX_PKGb.sql" sqlplus user/password @sql_deploy.sql $FILE_NAME echo "end of shell ...
2
votes
5answers
59k views

ORA-01017: invalid username/password; logon denied from sql developer but sqlplus logins

I've a strange behaviour of Sql Developer with OS Authentication, 4.1.3 32/64bit, gives ORA-01017 while sqlplus is logging in without any problem. This is the example answer sqlplus gives me: ~ ...
1
vote
1answer
44 views

Why does the scipt executes only once the sqlscript

the following script is pretty simple, but it works not as expected. I searched for an answer but I am stuck. #!/bin/bash db_con=user/pw@db bname='filename' for f in $(seq 1 10); do sqlplus -S ...
-2
votes
2answers
203 views

Trying to understand “tns_alias”

What would be tns_alias on this syntax? sqlplus -L user_name/Password@tns_alias @d:\my_bat_file\sql_script.sql
1
vote
2answers
4k views

CMD prompt can't display Unicode characters that are stored in oracle database correctly

I've been meddling with charset/encoding problems of Oracle database, PL/SQL developer and JDBC and these are what I want to achieve: Input Unicode characters from a browser into the database Display ...
1
vote
1answer
1k views

Accept use in sqlplus

I want to ask in SQL script for a start and finish date with accept but I get an error. accept v_FechaInicio date format 'DD/MM/YYYY-HH24:MI:SS' prompt 'Fecha de inicio ('DD/MM/YYYY-HH24:MI:SS'): ' ...
-2
votes
1answer
8k views

entering to database through sqlplus from putty

i have logged in to Putty. I need to connect to sqlplus to issue SQL commands. but when I type sqlplus it is throwing an error 'sqlplus not found'. what should I do? can somebody tell me how will I ...
0
votes
1answer
960 views

connect to sqlplus without writing as sysdba [closed]

I want to connect sqlplus sys/test without writing as sysdba. I'm wondering if there is a way to avoid that.
3
votes
2answers
10k views

How to create database/tablespace/schema and users for quickstart developers on Oracle 12?

Background I need to create a contained development space for a new application. This requires a user account to connect with all permissions, such as create/drop tables and stored procedures. ...
1
vote
0answers
642 views

Conditional flow in sqlplus

I have script for SQL plus, which I use to create user and get arguments for username and password. I want the script to do more things when it runs on oracle 12c, but I'm trying to avoid writing ...