10-31-2012
Yes, wait command will hold until both sql1 & sql2 are completed, then only sql3 will be called.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
If I execute this script:
$ORACLE_HOME/bin/sqlplus -s <<EOF > oracle.log
$DB_id/$DB_pswd@$DB_server
start test.sql
EOF
the sql script executes with no errors.
IF I execute the following script:... (12 Replies)
Discussion started by: mh53j_fe
12 Replies
2. Shell Programming and Scripting
Hi-
I am trying to achieve the following in a script so I can schedule it on a cron job. I am fairly new to the unix environment...
I have written a shell script that reads a flat file and loads the data into an Oracle table (Table1) via SQLLDR. This Works fine. Then, I run a nested insert... (5 Replies)
Discussion started by: rajagavini
5 Replies
3. Shell Programming and Scripting
Hi,
I am a shell script which takes input parameters and performs various functions. My concern is, if we call the same shell script with different parameter values from different sessions, will the results be inconsistent?
Are there any precautions I need to take inorder to avoid conflicts... (1 Reply)
Discussion started by: jamjam10k
1 Replies
4. Shell Programming and Scripting
Hi Experts,
There is a shell script that accepts positional parameter between 1-25 to execute case statement of script depending upon the parameter passed.
Now I need to run all the 25 sessions parallely. In each option of case statement it is connecting with sqlplus and executing a select... (11 Replies)
Discussion started by: Opamps123
11 Replies
5. UNIX for Advanced & Expert Users
Hi Experts:
I have a shell script that's kicked off by cron. Inside this shell script, I need to kick off two or more oracle sql scripts to process different groups of tables. And when both sql scripts are done, I will continue in the shell script to do other things like checking processing... (3 Replies)
Discussion started by: huasheng8
3 Replies
6. Shell Programming and Scripting
Hi, this's Pom. I'm quite a new one for shell script but I have to do sql on shell script to query some information from database.
I found a concern to get a new line...When I run my script, it retrieves all data as wondering but it's shown in one line :(
What should I do? I'm not sure that... (2 Replies)
Discussion started by: Kapom
2 Replies
7. Shell Programming and Scripting
Hi Friends,
I am trying to write a shell which will invoke 3 CTAS (ORACLE create table XXX as select * from YYYY). The approximate time for one CTAS is around 25 mins. So i want to run the CTAS script parallely.
My pseudocode is as below.
Main script
nohup sh CTAS1.sh &... (3 Replies)
Discussion started by: Showdown
3 Replies
8. Shell Programming and Scripting
Hi,
I'm trying to do teh below thing.
I have a single script which uses 3 different parameters to do 3 different work like belwo.
test1.sh par1 -- it shuts down an instance
test1.sh par2 -- it shuts down an instance
test1.sh par3 -- it shuts down an instance
Now I created a script... (7 Replies)
Discussion started by: bhaski2012
7 Replies
9. Shell Programming and Scripting
Hello,
This is my Script which configure a list of nodes. ( 40 nodes, and the configuration 10 minutes)
#! /bin/sh
if
then
echo "USE: ./start.sh nodes
else
nb_lignes=`wc -l $1 | cut -d " " -f1`
echo "$nb_lignes machines"
for i in $(seq $nb_lignes)
//instructions
done
fi
My... (2 Replies)
Discussion started by: chercheur111
2 Replies
10. UNIX for Beginners Questions & Answers
Hi Folks,
I have requirement to pull a bunch of SQL's from a table in DB and execute them in parallel and update the status of each query as and when they complete. Can you please help me with ideas on how this can be achieved?
create table list_of_sql
(
id number,
full_sql... (3 Replies)
Discussion started by: member2014
3 Replies
LEARN ABOUT SUNOS
pthread_barrier_wait
pthread_barrier_wait(3C) Standard C Library Functions pthread_barrier_wait(3C)
NAME
pthread_barrier_wait - synchronize at a barrier
SYNOPSIS
cc -mt [ flag... ] file... [ library... ]
#include <pthread.h>
int pthread_barrier_wait(pthread_barrier_t *barrier);
DESCRIPTION
The pthread_barrier_wait() function synchronizes participating threads at the barrier referenced by barrier. The calling thread blocks
until the required number of threads have called pthread_barrier_wait() specifying the barrier.
When the required number of threads have called pthread_barrier_wait() specifying the barrier, the constant PTHREAD_BARRIER_SERIAL_THREAD
is returned to one unspecified thread and 0 is returned to each of the remaining threads. At this point, the barrier is reset to the state
it had as a result of the most recent pthread_barrier_init(3C) function that referenced it.
The constant PTHREAD_BARRIER_SERIAL_THREAD is defined in <pthread.h> and its value is distinct from any other value returned by
pthread_barrier_wait().
The results are undefined if this function is called with an uninitialized barrier.
If a signal is delivered to a thread blocked on a barrier, upon return from the signal handler the thread resumes waiting at the barrier if
the barrier wait has not completed (that is, if the required number of threads have not arrived at the barrier during the execution of the
signal handler); otherwise, the thread continues as normal from the completed barrier wait. Until the thread in the signal handler returns
from it, it is unspecified whether other threads may proceed past the barrier once they have all reached it.
A thread that has blocked on a barrier does not prevent any unblocked thread that is eligible to use the same processing resources from
eventually making forward progress in its execution.
Eligibility for processing resources is determined by the scheduling policy.
RETURN VALUES
Upon successful completion, the pthread_barrier_wait() function returns PTHREAD_BARRIER_SERIAL_THREAD for a single (arbitrary) thread syn-
chronized at the barrier and 0 for each of the other threads. Otherwise, an error number is returned to indicate the error.
ERRORS
The pthread_barrier_wait() function will fail if:
EINVAL The value specified by barrier does not refer to an initialized barrier object.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Interface Stability |Standard |
+-----------------------------+-----------------------------+
|MT-Level |MT-Safe |
+-----------------------------+-----------------------------+
SEE ALSO
pthread_barrier_destroy(3C), attributes(5), standards(5)
SunOS 5.10 30 Jan 2004 pthread_barrier_wait(3C)