Here is the script:
#!/bin/ksh
send_page() {
for DBA in ${1}; do
echo in
echo $DBA
case $DBA in
jesse) echo "jesse";;
mika) echo "mika";;
esac
done
}
send_page "$1"
$t.sh jesse
in
jesse
jesse
$t.sh {jesse,mika}
in
{jesse,mika}
Ummm..interesting.
Are using AIX/HP/Sun. I originally built this script in HP and like I said it worked fine. I am currently working in an AIX environment and I am getting the bizarre results I noted.
JS
I am running this script in AIX (tried SH, KSH). I would like to pass in a comma deliminted list and have the script parse the list. I ran this same script in an HPUX environment and it works perfectly. I thought if I used the same shell it wouldnt matter what flavor of Unix it was on (obviously...
All,
I have an input file:
$cat t.txt
A B C D
$cat t.sh
while read line
do
echo $line
done < t.txt
$./t.sh
A B C D
My question is: How do I "keep" the spaces? I would like the variable to hold the entire formatted line of the input file ("A B C D"). I know I can...
Thanks alot, this worked. I thought non-greedy expression where supported. I've seen documentation about them, perhaps referring to regular expressions in general. Anyways thanks, appreciate it
Hello,
I have an xml file all on one line. I would like to separate all tags on separte lines. I am having problems creating the proper regex to grab the shortest pattern. Here is my example file:
<a>who cares</a><b>not me</b>
my script:
gsub(/<\/(.*)?>/, "n")
outfile:
<a>who caresn...
I narrowed the problem down to the specific issue yet I can't explain why awk does this. If someone can explain the logic behind this I would appreciate it.
Input file:
20030101
20030201
20030101
AWK script:
BEGIN {
CMD = "t.sh "
}
{
CMD $0 | getline MYDATE;
close(CMD);
print...
I have an issue with an awk script I am stumped on and am looking for some assistance. Here is an example of an input file:
5019970714 W 4 0000000132
5019970721 W 4 0000000000
5020040201 20040315 F 4 0000001291
When $3 ==...
Hi,
I have a macro that is importing data, what I would like to do is import data from a path specified in a form rather than having it hard coded into the macro. Is there a way to do this.
Thanks
I'm not familiar with recordcount working the way you discribed however you can simply test to see if recordcount is greater than 0. For example
if ( rst.recordcount > 0 ) then
do whatever
else
do whatever
end if
Thanks Guys,
Currently I have exactly what cmmrfrds proposed and it seems to be working I was just hoping there was a way to build these queries to save time.
Thanks for the help
JesCat
Mike,
That is what I thought as well. However, when I do that I get the error stating "Operation must use an updatable query". If I build this query as a select query it finds the records that I need deleted, but when I change it to a delete query I get the error I mentioned. Any...
Hello,
I have two tables, and would like to delete records out of the second table if they are found in the first based on a key of three fields. Take the following example the first threee columns make up the key of each table:
Table 1 Table 2
1 1 1 3 1...
I would like to spin through a directory and process files older than 1 day old is there a better way to do this other than using the find command.
JesCat
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.