i want to use multple sql count statements and store these count values in unix variable but in one connection only i.e. in only 1 time database should be hit ,which is the main requirement. (1 Reply)
I want to store the sql query output into a variable
#!/bin/ksh
ORACLE_SID=DB01;
export ORACLE_SID;
export FILE_PATH=/home/asg/Tmp
# Order Checking
echo " removing old files "
rm $FILE_PATH/Malformed_Order.txt
echo " Enter the Malformed Order ....!"
read orders
echo "Regrade... (5 Replies)
Hi,
I am currently filtering a file, "BUILD_TIMES", that has multiple column of information in it. An example of the data is as follows;
Fri Nov 5 15:31:33 2010 00:28:17 R7_BCGNOFJ_70.68
Fri Nov 5 20:57:41 2010 00:07:21 R7_ADJCEL_80.6
Wed Nov 10 17:33:21 2010 00:01:13 R7_BCTTEST3_80.1X... (7 Replies)
Say I have two tables like below..
status
HId sName dName StartTime EndTime
1 E E 9:10 10:10
2 E F 9:15 10:15
3 G H 9:17 10:00
logic
Id devName capacity free Line
1 E 123 34 1
2 E 345 ... (3 Replies)
Hello,
I am very new to shell scripting and I am not sure of how best to handle the following scenario. I need to query a list of values from a table. I need to store those results and use them to selectively delete values in yet another table in a separate database. I do know how to store the... (3 Replies)
Hello,
I would like to ask for help with csh script.
An example of an input in .txt file is below, the number of lines varies from file to file and I have 2 or 3 columns with values. I would like to read all the values (probably one by one) and set them to independent unique variables that... (7 Replies)
Is it possible to have a user input multiple words in one line and have the script assign each word a variable? I'm stuck please assist.
Example using "BILL JOHN SARA JILL" as what the user could type:
printf "Enter account names: " BILL JOHN SARA JILL
read input (9 Replies)
Hi,
I have a text file that has data like this
chr1 156106712 156106819 LMNA 8 + 1 147
chr1 156106712 156106819 LMNA 8 + 2 147
chr1 156106712 156106819 LMNA 8 + 3 148
chr1 ... (4 Replies)
Hello All,
just wanted to export multiple tables from oracle sql using unix shell script to csv file and the below code is exporting only the first table.
Can you please suggest why? or any better idea?
export FILE="/abc/autom/file/geo_JOB.csv"
Export= `sqlplus -s dev01/password@dEV3... (16 Replies)
Discussion started by: Hope
16 Replies
LEARN ABOUT SUNOS
tcflush
tcflush(3C) Standard C Library Functions tcflush(3C)NAME
tcflush - flush non-transmitted output data, non-read input data or both
SYNOPSIS
#include <termios.h>
int tcflush(int fildes, int queue_selector);
DESCRIPTION
Upon successful completion, tcflush() discards data written to the object referred to by fildes (an open file descriptor associated with a
terminal) but not transmitted, or data received but not read, depending on the value of queue_selector:
o If queue_selector is TCIFLUSH it flushes data received but not read.
o If queue_selector is TCOFLUSH it flushes data written but not transmitted.
o If queue_selector is TCIOFLUSH it flushes both data received but not read and data written but not transmitted.
Attempts to use tcflush() from a process which is a member of a background process group on a fildes associated with its controlling termi-
nal, will cause the process group to be sent a SIGTTOU signal. If the calling process is blocking or ignoring SIGTTOU signals, the process
is allowed to perform the operation, and no signal is sent.
RETURN VALUES
Upon successful completion, 0 is returned. Otherwise, -1 is returned and errno is set to indicate the error.
ERRORS
The tcflush() function will fail if:
EBADF The fildes argument is not a valid file descriptor.
EINVAL The queue_selector argument is not a supported value.
ENOTTY The file associated with fildes is not a terminal.
The tcflush() function may fail if:
EIO The process group of the writing process is orphaned, and the writing process is not ignoring or blocking SIGTTOU.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-------------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-------------------------------+
|Interface Stability |Standard |
+-----------------------------+-------------------------------+
|MT-Level |MT-Safe, and Async-Signal-Safe |
+-----------------------------+-------------------------------+
SEE ALSO tcdrain(3C), attributes(5), standards(5), termio(7I)SunOS 5.10 14 Aug 2002 tcflush(3C)