[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index] [Date Index] [Thread Index]
[SQR-USERS Info] [SQRUG Home Page]

[sqr-users] SQR return status 0 if missing input parameter



To all 

SQR/8.1/HP 9000/HPUX B.11.00/Oracle 8.1.7

I write a new SQR program X with three input
parameters. 

begin-program 
   input $a 'Enter a:' 
   input $b 'Enter b:' 
   input $c 'Enter c:' 
end-program 


If  I run the program X in batch mode ( sqrt X a b c
), the program works OK too. 

If I miss one or more of the parameters, the program
abends with "(SQR 2500) Error getting INPUT."   This
is perfectly fine too. 

Since I need to run the program X a few times with
different parameters, I set up a script like this 

while read p1 p2 p3 
   do 
      sqrt X p1 p2 p3 
   done < parm.txt 

where parm.txt consists of 2 lines: 
a b c 
e f g 

The script runs successful with this parm.txt.     

If I only have 'a' and miss the 'b' and 'c' in the
first line of parm.txt file, the program prompts
'Enter b:' and 'Enter c:' on the screen, 
wait for a few seconds, return a status of zero
without processing the next line ( e f g ). 


Do any of you know why ZERO is returned?  How to
re-solve this?   


Terence


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

_______________________________________________
sqr-users mailing list
sqr-users@sqrug.org
http://www.sqrug.org/mailman/listinfo/sqr-users