Creation of Oracle table through shell scripting


Login or Register to Reply

 
Thread Tools
# 1  
Question Creation of Oracle table through shell scripting

Hi,

I am trying to create a table through shell scripting . I used a command sqlplus -s to connect to sqlplus and user as sysdba. but there is a problem in it. can anyone please solve this .

#!/bin/bash

$(`sqlplus -s / as sysdba <<eof

create table sample (id,int);
insert into sample values(1,'value');

exit;
eof`)
Unregistered
# 2  
This room i for registering or account problems...
Please register if you wish to post in our forums, thanks
Thread closed
Login or Register to Reply

|
Thread Tools

More UNIX and Linux Forum Topics You Might Find Helpful
How to update a Oracle table through shell scripting?
karthick.cho
My Code is get_week_date() { `sqlplus -s ${DQM_SQL_LOGON}@${DQM_SID} << EOF SET ECHO OFF SET FEEDBACK OFF SET PAGES 0 SET SERVEROUTPUT ON SET VERIFY OFF SET TRIMSPOOL ON (update file_level_qc fq set FQ.DATA_FILE_NAME='Hyvee_Pharmacy_Solutions_201304_v1.txt'...... Shell Programming and Scripting
2
Shell Programming and Scripting
Shell script to query Oracle table
ken002
Hi, unix gurnis I need help for following requirement for writing a shell scritp. log in to oracle database, query one table total records (select count(*) from table1), pass the return value to a file. Thanks in advance... Shell Programming and Scripting
2
Shell Programming and Scripting
Create a table using shell scripting
ultimatix
Hi Can we create a rectangular table as i have attached in the query . This is primarily for populating the created table with data gathered . Hope I made myself clear ... Pls suggest Thanks... Shell Programming and Scripting
1
Shell Programming and Scripting
Help in Shell scripting to modify the User Creation script in oracle database.
rparavastu
Hi, I have several users to create on my test Oracle database taking the scripts from the Production Oracle database. I have a separate text file where I have user-id and passwords maintained. I need help in writing a shell script to go thru the user creation scripts and replace VALUES...... Shell Programming and Scripting
1
Shell Programming and Scripting
update a oracle table using shell script
ann_124
Hi, I would like to know how to update a table in Oracle database, if a command in one shell script either successfully completes or it fails.(like Y if its success or N if its a failure) While the command is running,I am able to view the log file created in the Unix machine.After the command...... Shell Programming and Scripting
2
Shell Programming and Scripting

Featured Tech Videos