hi,
Please explain the below stmt.
P=1234
var1=:/a/b/c/file.dat
printf "%s %s\n" "$" "${var1#?}"
Output is:
1234 /a/b/c/file.dat
What is #? in printf stmt? by using that the first character( : ) of "var1" variable is not displayed in output. How is that? please explain..
... (1 Reply)
I am working on a C/Unix application from last 2 years which communicates with other systems using proprietary format of my client. We have a function written in C which returns integer, which is response from other system to the request message initiated by my system. This return value is then... (1 Reply)
Hi All
I have a requirement where in I am stuck. There is a shell script that is being developed by me. It consist of the sql stmt also. I need to export a variable called HOMEPAGE with a value say www.abc.com. and then use this $HOMEPAGE variable in the sql stmt. My ultimate aim is to fetch all... (1 Reply)
CT=0
while read LINE
do
# Check to see if the LINE is non-empty, and has a <td> tag in it.
if
then
# Increase the TD counter by 1
CT=`echo "$CT+1"`
fi
done <test.htmthrows this error: ksh: test: argument expected
test.htm
<tr>
<td>text</td... (4 Replies)
hi All
Please explain the below statement in RED?What does this mean?
perl /HDS/common/operations/Quality_Team/Nirvana/WEEKLY_OOPS/sql_dump.pl --sql "select * from WEEKLY_REPORT order by test_case, type" --username=ddb_qa --password=ddb_qa123 --sid=pldeldb --output... (1 Reply)
Hi frnds
Im facing an issues while trying to compare string using IF stmt, my code is:
chkMsgName=`Service Fee Detail`
if
then
if
then
if
then
echo "Valid File Ready for processing"
fi
fi
... (5 Replies)
Hello All,
Need help urgently.. i have a scenario where i have two files
1) mireport_20111406.txt
2) PRLIHSP01_8080.2011-06-11-15_26_31
----------
I want a query something similar to this algorithm :-
Case
when file_name is like mireport
then extract_date=14-06-2011
when... (4 Replies)
my code does somthing like this:
#!bin/ksh
sqlplus / | While read id
do
temp=`echo $id`
i = i+1
done
j=0
while
do
--connecting to sql and executing a Stored proc for 1st id
--checking for the status
status = $?
if
error
--need to... (1 Reply)
How can I merge the move statements with the "FOR" loop to do a move of a file right after it zips it and not wait until all of the files are zipped to move all outisde the for loop.
Here is my current code:
for file in `ls -rt $svdumpdir/* | grep -v '.gz$' | grep '.gtt$' `
do
echo... (8 Replies)