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

Re: Q: record lenght as variable



In your setup section, you define the size of the record

#define rec_size1       1000


And then, what you define will get passed as a parameter. 
 
OPEN $output_file as 1 for-writing record = {Rec_Size1}
        status = #filestat1
IF #filestat1 != 0
  SHOW 'Error Opening File: ' $output_file
END-IF

Hope this helps,
Sam

<<< nitin rathor <tintin_n@HOTMAIL.COM> 10/22 12:13a >>>
Hello EveryBody ,

I want to pass record lenght of the file as the parameter and to use it in
the "open" statement for file .
I tried using both # and $ variables but got the error opening the file .

Is it possible , first  of all to give variable as record length?
IF yes then how ?

I am using SQR 3 .

Thanks ,
Nitin.

______________________________________________________
Get Your Private, Free Email at http://www.hotmail.com