05-18-2009
Thanks vgersh,
But that is not what I am looking at and I apologise that I confused you.
I should explain because I am really stuck.
In an oracle table I have
LOAD_DT=5/1/2009 DATE datatype
RUN_DT=5/5/2009 DATE datatype
with the help of spool file I am picking these variables up like 02-MAY-2009 and 05-MAY-2009
Now my question is with a do while loop I need to get the dates 03-MAY-2009, 04-MAY-2009 and 05-MAY-2009.
I am confused at where to initialize and totally confused with the loop.
I did this
while [ $LOAD_DT -lt $RUN_DT ]
do
#Here I will write a sqlplus code to increment the date
#I will get my other work done here
stop condition
done
#Here I will update my table with the next day sqlplus code
Just please suggest me the do while loop syntax for this case and the stop condition.
I am sure I am messing up at the initialising or stop condition.
Thanks to all of you,
10 More Discussions You Might Find Interesting
1. Programming
hi all,
i have written the following code:
while(proceed !='Y' && proceed!='N' && proceed!='y' && proceed!='n')
{
printf("\nPress \n\t 'Y' or 'y' to continue \n\t 'N' or 'n' to cancel:");
scanf("%c",&proceed);
}
the output i am gettin is:
Press
'Y' to continue
... (1 Reply)
Discussion started by: mridula
1 Replies
2. Shell Programming and Scripting
Hi,
I have a directory called logs in which i have the log files.
i have to touch the file before deleting it.
i am doing like this
filestodelete="*.log* *log*"
for files in $filestodelete
do
touch $files $files.$(date +%a)
rm -f $filestodelete
done
touch is not working... (5 Replies)
Discussion started by: namishtiwari
5 Replies
3. Shell Programming and Scripting
Hi Guys,
This is my code.. I am getting an error in the inside while statement when comparing.. I am not able to figure it out.. Pls help me...
while read value fatherid son_id top_id r_type
do
inside_value=1;
echo $inside_value;
echo $r_type;
while
do
echo... (6 Replies)
Discussion started by: mac4rfree
6 Replies
4. Shell Programming and Scripting
Hi
What is wrong with this loop
it was taken has a example in book!!!
it returns
then
/usr/sbin/svcadm disable ppserv
else /usr/sbin/ppadmin stop
fi
} (3 Replies)
Discussion started by: Ex-Capsa
3 Replies
5. Shell Programming and Scripting
hi
I had created a while loop in a script file called whiletest.sh as follows
as follows:
count=0
max=10
while
do
echo $count
echo count=$(count+1)" "
done
echo "value of count:$count"
then i run the script with the command
sh whilestest.sh
but its giving me an error... (5 Replies)
Discussion started by: angel12345
5 Replies
6. UNIX for Dummies Questions & Answers
I have a while loop with -f and -o option.Can any one please tell me what that stands for?The Sample code is as follows:-
while
do
## some processing
done (10 Replies)
Discussion started by: Param0073
10 Replies
7. Shell Programming and Scripting
Hi Script Gurus,
I am facing issue with while loop in bash. The while loop is running as end less loop even after given criteria does not meet.
STATE_BEFORE_SPLIT () {
for clone in $Clonegroups; do
state=$( $Navicmd -listclone -name $clone -cloneid $Cloneid |awk... (3 Replies)
Discussion started by: RobP
3 Replies
8. Shell Programming and Scripting
Hi,
I work on Ab-initio ETL tool which is based on Unix. I made a small script which has two loop's one with in another. All the functionality is working for the first line of outer loop but when it comes to other lines of outer loop it is throwing error as command not found. Below is the... (4 Replies)
Discussion started by: Ravindra Swan
4 Replies
9. Shell Programming and Scripting
I am trying to do a while do loop that asks for a password and returns if the password entered is incorrect. I have that part working however i want to modify it so that if a similar word is entered it will read "that is close but incorrect" and i cannot seem to get it working, being new in the... (6 Replies)
Discussion started by: lm5522
6 Replies
10. Shell Programming and Scripting
Hi all,
a problem with a loop. Imagine it starts with
var1="$(cat txtif.out )"while
do
echo file1
echo file2
echo y > txtif.out
if
then
break
fi
done
exit 0
the problem is that if the file is changing during the loop seems to continue as it reads "x" state,... (5 Replies)
Discussion started by: Board27
5 Replies
LEARN ABOUT DEBIAN
gdcmtar
gdcmtar(1) GDCM gdcmtar(1)
NAME
gdcmtar - Concatenate/Extract DICOM files.
SYNOPSIS
gdcmtar [options] file-in file-out
DESCRIPTION
The gdcmtar is a command line tool used to tar/untar multi-frames images (including SIEMENS MOSAIC file)
PARAMETERS
file-in DICOM input filename
file-out DICOM output filename
options
options
--enhance enhance (default)
-U --unenhance unenhance
-M --mosaic Split SIEMENS Mosaic image into multiple frames.
-p --pattern Specify trailing file pattern.
--root-uid Root UID.
general options
-h --help
print this help text and exit
-v --version
print version information and exit
-V --verbose
verbose mode (warning+error).
-W --warning
warning mode, print warning information
-E --error
error mode, print error information
-D --debug
debug mode, print debug information
environment variable
GDCM_ROOT_UID Root UID
Typical usage
SIEMENS Mosaic
$ gdcminfo MR-sonata-3D-as-Tile.dcm
MediaStorage is 1.2.840.10008.5.1.4.1.1.4 [MR Image Storage]
TransferSyntax is 1.2.840.10008.1.2.1 [Explicit VR Little Endian]
NumberOfDimensions: 2
Dimensions: (384,384,1)
...
$ gdcmtar --mosaic -i MR-sonata-3D-as-Tile.dcm -o mosaic --pattern %03d.dcm
Will output:
-rw-r--r-- 1 mathieu mathieu 72882 2009-08-10 11:14 mosaic000.dcm
-rw-r--r-- 1 mathieu mathieu 72886 2009-08-10 11:14 mosaic001.dcm
-rw-r--r-- 1 mathieu mathieu 72886 2009-08-10 11:14 mosaic002.dcm
-rw-r--r-- 1 mathieu mathieu 72886 2009-08-10 11:14 mosaic003.dcm
-rw-r--r-- 1 mathieu mathieu 72886 2009-08-10 11:14 mosaic004.dcm
-rw-r--r-- 1 mathieu mathieu 72886 2009-08-10 11:14 mosaic005.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic006.dcm
-rw-r--r-- 1 mathieu mathieu 72882 2009-08-10 11:14 mosaic007.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic008.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic009.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic010.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic011.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic012.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic013.dcm
-rw-r--r-- 1 mathieu mathieu 72882 2009-08-10 11:14 mosaic014.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic015.dcm
-rw-r--r-- 1 mathieu mathieu 72882 2009-08-10 11:14 mosaic016.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic017.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic018.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic019.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic020.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic021.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic022.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic023.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic024.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic025.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic026.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic027.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic028.dcm
-rw-r--r-- 1 mathieu mathieu 72884 2009-08-10 11:14 mosaic029.dcm
-rw-r--r-- 1 mathieu mathieu 72882 2009-08-10 11:14 mosaic030.dcm
$ gdcminfo mosaic000.dcm
MediaStorage is 1.2.840.10008.5.1.4.1.1.4 [MR Image Storage]
TransferSyntax is 1.2.840.10008.1.2.1 [Explicit VR Little Endian]
NumberOfDimensions: 2
Dimensions: (64,64,1)
...
SEE ALSO
gdcmdump(1), gdcmraw(1), gdcminfo(1)
COPYRIGHT
Copyright (c) 2006-2011 Mathieu Malaterre
Version 2.2.0 Tue Feb 5 2013 gdcmtar(1)