agreed.  I tend not to use <cfloop query="foo">, but prefer <cfloop index
="i" from="1" to="#queryname.recordcount#">.  and if looping only 10 times,
or whatever less than the recordcount, then wrap it inside the check for
recordcount GT 0

incidentally, does <cfloop query="blah" startrow="1" endrow="
#blah.recordcount#"> work (i.e. doesn't loop), or does it still loop at
least once?


Duncan Cumming
IT Manager

http://www.alienationdesign.co.uk
mailto:[EMAIL PROTECTED]
Tel: 0141 575 9700
Fax: 0141 575 9600

Creative solutions in a technical world

----------------------------------------------------------------------
Get your domain names online from:
http://www.alienationdomains.co.uk
Reseller options available!
----------------------------------------------------------------------
----------------------------------------------------------------------


                                                                                       
                                               
                    Sridhar Pedamallu                                                  
                                               
                    <sridhar.pedamallu@clearthinking        To:     
[EMAIL PROTECTED]                                       
                    group.com>                              cc:                        
                                               
                                                            Subject:     RE: [ cf-dev 
] CFLOOP in CFMX                                
                    12/06/02 01:33 PM                                                  
                                               
                    Please respond to dev                                              
                                               
                                                                                       
                                               
                                                                                       
                                               



I accept that my code will be stable and efficient if i check records
before
loop.

But I don't think my code is RUBBISH.

Because cfloop should take number of records first and then when it start
looping over it then it should take startrow attribute.
It shouldn't start the loop first from startrow attribute and then look for
records.


-----Original Message-----
From: Stephen Moretti [mailto:[EMAIL PROTECTED]]
Sent: Friday, December 06, 2002 12:57
To: [EMAIL PROTECTED]
Subject: Re: [ cf-dev ] CFLOOP in CFMX


But its still rubbish code.....

Check to see if there are records before you try to process them....
It'll make your code work, be most stable and more efficient.


----- Original Message -----
From: "Sridhar Pedamallu" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, December 06, 2002 12:42 PM
Subject: RE: [ cf-dev ] CFLOOP in CFMX


> But it works fine in CF5
>
> -----Original Message-----
> From: Taz -=TT=- [mailto:[EMAIL PROTECTED]]
> Sent: Friday, December 06, 2002 12:40
> To: [EMAIL PROTECTED]
> Subject: Re: [ cf-dev ] CFLOOP in CFMX
>
>
> I wouldn't say that its really a bug though... you are basically telling
CF
> to start at row 1, which doesn't exist.
>
> Taz
>
>
> > Will there be any fix for this.
> > Because i have almost 200 cfm pages and atleast 300 loops :(
>
>
> --
> ** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
>
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> For human help, e-mail: [EMAIL PROTECTED]
>
> --
> ** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
>
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> For human help, e-mail: [EMAIL PROTECTED]
>
>



--
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]

--
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]






-- 
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]

Reply via email to