I have a migration program that creates directories based on dates, e.g 20090714 20090812 etc.. Based on their requirements, the user will select the directory they want to perform an action on.
Currently, this is a snippet of the code I use
Currently the user has to type in the value of the date and this isn't the most elegant of ways. Consequently, I wanted to simplify this process and this is where I need help.
Is it possible to have a situation where I display the list of date directories along the lines of
(1) 20090714 (2) 20090812 (3) 20090901
They can then select either 1 or 20090714
I have no way of knowing how many dates there could be, 1 or 10 is possible.
I'm not even entirely sure this is something I can do in shell or even perl. All help as always appreciated
Hi,
I am using awk here.
Inside an awk script, I have a variable which contains a very long XML data in string format (500kb).
I want to pass this data (as argument) to curl command using system function.
But getting Too many arguments error due to length of string data(payloadBlock).
I... (4 Replies)
How to use "mailx" command to do e-mail reading the input file containing email address, where column 1 has name and column 2 containing “To” e-mail address
and column 3 contains “cc” e-mail address to include with same email.
Sample input file, email.txt
Below is an sample code where... (2 Replies)
Hi,
I have line in input file as below:
3G_CENTRAL;INDONESIA_(M)_TELKOMSEL;SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL
My expected output for line in the file must be :
"1-Radon1-cMOC_deg"|"LDIndex"|"3G_CENTRAL|INDONESIA_(M)_TELKOMSEL"|LAST|"SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL"
Can someone... (7 Replies)
Hallo,
i need a Prompting read in my script:
read -p "Enter your command: " command
But i always get this Error:
-p: is not an identifier
When I run these in c-shell i get this error
/usr/bin/read: read: bad option(s)
How can I use a Prompt in the read command? (9 Replies)
Hello,
Can anyone let me know what is the maximum file size that can be given as input for the "Diff" Command in Unix?
I have a file size as large as 28MB and which can also increase. Will I face any issues with such a file size. If yes, What is the other alternative.
Thanks in advance for... (1 Reply)
In this post, Perderabo's script says
echo 05/06/25 14:15:56 | IFS=" /:" read Y1 M1 D1 h1 m1 s1
which, if I am not wrong, will break the input into Y1, M1 et al.
I tried the following in my code
#! /bin/ksh
# per.sh
typeset -R2 HOUR=00
typeset -R2 MIN=00
typeset -R2 SEC=00
... (2 Replies)
I want to prompt a user for input but I want it to timeout after a specified time if no response is given. I tried the sleep command but this does not work. I am using ksh.
Thanks. (10 Replies)