[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index]
[Date Index]
[Thread Index]
[SQR-USERS Info]
[SQRUG Home Page]
Re: dynamic loops
- Subject: Re: dynamic loops
- From: Robert Foster <robert.foster@RADIOLOGY.MSU.EDU>
- Date: Tue, 17 Sep 2002 12:11:27 -0400
- Organization: Mid-Michigan MRI, Inc.
- References: <200209170600.g8H60Co10714@list.iex.net>
I use an old version of SQR and I've never really had to do this but
this might work...
let #LOOP_COUNTER = to_num($user_input_variable)
let #LOOP = 0
begin-select
columns
! other sqr statement
if #LOOP < #LOOP_COUNTER
! increment loop counter
add 1 to #LOOP
else
exit-select
end-if
where ... etc.
order by ... etc.
end-select
===
Bob Foster
I/S Coordinator
Mid-Michigan MRI, Inc.
Direct Line: (517) 364-2673
mailto:rkf@radiology.msu.edu
> Date: Mon, 16 Sep 2002 09:22:56 +0200
> From: Aleksandra Polniak <opolniak@AIUT.COM.PL>
> Subject: dynamic loops
>
> Hello
>
> I am new to SQR, so forgive me if this is "stupid question" but I can't =
> find answer anywhere. I need to make a loop in my report in order to =
> print only at most X measurements. Parameter X should be taken from user =
> at runtime.=20
>
> Aleksandra Polniak