ok, i follow your maths.  but are you sure the difference is zero?  as you
said before:

"it wont even make a 1ms difference to your page if you have a cfif instead
of an IIF."

so is it 0.5ms, 0.0ms, 0.99ms?  i assume you've ran some metrics on this.

"Never use IIF - If you can help it, don't use the IIF function. It is half
as fast as a normal CFIF. "
http://www.fusionauthority.com/Article.cfm?ArticleID=2511

"The "immediate if" function (IIF) will process nearly two times slower
than a cfif/cfelse block that accomplishes the same thing"
http://www.phptr.com/isapi/product_id~%7B0661582F-55B1-40C7-8B29-61D2E438E89A%7D/articles/index.asp

etc.  so either there is an infinitesimal difference, or it takes twice as
long.


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!
----------------------------------------------------------------------
----------------------------------------------------------------------


                                                                                       
                               
                    "Snake                                                             
                               
                    Hollywood"              To:     <[EMAIL PROTECTED]>                
                     
                    <[EMAIL PROTECTED]        cc:                                      
                                 
                    kepit.net>              Subject:     RE: [ cf-dev ] Nested IIf 
functions                          
                                                                                       
                               
                    21/01/2004 16:27                                                   
                               
                    Please respond                                                     
                               
                    to dev                                                             
                               
                                                                                       
                               
                                                                                       
                               



If the page takes 100ms without IIF and 100ms with IIF, it doesn't matter
how many page requests u get, they still take the same time to render.

100 vistors x 100ms still equals the same.
The total combined may add a few ms extra as all the fractions of a ms add
up, but that's like counting grains of sand.

Russ Michaels
Macromedia/Allaire Certified ColdFusion Developer

CFMX Hosting
Phone: 0845 456 3487
Tech Support: 0906 9607800
FAX: 0709 2212 636
WEB: cfmxhosting.co.uk

>Please use the support helpdesk on our web site to submit support tickets.
<

Join our ColdFusion Developer discussion lists.
Send an e-mail to [EMAIL PROTECTED]



> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]
> Sent: 21 January 2004 16:18
> To: [EMAIL PROTECTED]
> Subject: RE: [ cf-dev ] Nested IIf functions
>
>
>
> what if you had say 100 sites, each with 100 pages.  in each
> of those pages you use IIF where you could have used
> something faster.  each site gets thousands of hits a day.
> could that not have a cumulative effect on cf server's performance?
>
> the whole point of writing code that is marginally faster in
> performance than something else, isn't because it's
> super-duper faster on one run-through, or that you're only
> meant to use it in nested loops.  it's to improve overall
> performance in the long run, isn't it?
>
>
> 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!
> ----------------------------------------------------------------------
> ----------------------------------------------------------------------
>
>
>
>
>                     "Snake
>
>                     Hollywood"              To:
> <[EMAIL PROTECTED]>
>                     <[EMAIL PROTECTED]        cc:
>
>                     kepit.net>              Subject:     RE:
> [ cf-dev ] Nested IIf functions
>
>
>                     21/01/2004 16:14
>
>                     Please respond
>
>                     to dev
>
>
>
>
>
>
>
>
> I hate when people start this.
> You will only see any overhead if you use hundreds of IIF
> statements in a page or in some sort of nested loop.
> Otherwise the difference is too small to notice, it wont even
> make a 1ms difference to your page if you have a cfif instead
> of an IIF.
>
> Russ Michaels
> Macromedia/Allaire Certified ColdFusion Developer
>
> CFMX Hosting
> Phone: 0845 456 3487
> Tech Support: 0906 9607800
> FAX: 0709 2212 636
> WEB: cfmxhosting.co.uk
>
> >Please use the support helpdesk on our web site to submit support
> >tickets.
> <
>
> Join our ColdFusion Developer discussion lists.
> Send an e-mail to [EMAIL PROTECTED]
>
>
> > -----Original Message-----
> > From: EWS [mailto:[EMAIL PROTECTED]
> > Sent: 21 January 2004 10:44
> > To: [EMAIL PROTECTED]
> > Subject: Re: [ cf-dev ] Nested IIf functions
> >
> >
> > Just a quick point. IIF is great but use sparingly. If possible use
> > CFSWITCH of CFIF as IIf does have a greater processing overhead. If
> > this is not possible then IIf is fine and does a great job.
> >
> > Just a thought
> >
> > On Wed, 21 Jan 2004 10:34:25 -0000, Tomo Smith
> > <[EMAIL PROTECTED]>
> > wrote:
> >
> > >
> > > #IIf(GetPatients.wait_time_mins[i] GT 381000,
> > >  DE("red"), 'IIf(GetPatients.wait_time_mins[i] GT 375000,
> > > DE("orange"),  DE("blue"))')#
> > >
> > > try the iif statement above.  I changed your DEs to use
> > double quotes,
> > > and
> > > your inner IIF has single quotes around it, otherwise it
> wont work!
> > >
> > > Cheers,
> > >
> > > Tom
> > >
> > >
> > >
> > > ----- Original Message -----
> > > From: "Osullivan Karl (RKB) Senior Analyst/Programmer"
> > > <[EMAIL PROTECTED]>
> > > To: "CF - Development Group" <[EMAIL PROTECTED]>
> > > Sent: Wednesday, January 21, 2004 10:27 AM
> > > Subject: [ cf-dev ] Nested IIf functions
> > >
> > >
> > >>
> > >> UHCWT Logo
> > >>
> > >>
> > >> Hello
> > >>
> > >> Is it possible to nest IIf statements, as I'm trying to do the
> > >> following:
> > >>
> > >> style="background-color:#IIf(GetPatients.wait_time_mins[i]
> > GT 381000,
> > >> DE('red'), IIf(GetPatients.wait_time_mins[i] GT 375000,
> > DE('orange'),
> > >> DE('blue')))#;"
> > >>
> > >> However, when I run this, the following message appears
> > >>
> > >>
> > >> Variable orange is undefined.
> > >>
> > >>
> > >>
> > >> Is my syntax wrong?  I thought it looked okay.  Obviously
> > the above
> > >> is within a <CFOUTPUT> tag.
> > >>
> > >>
> > >>
> > >>
> > >> Karl O'Sullivan
> > >> Senior Analyst/Programmer
> > >>
> > >> Computer & Network Services
> > >> UHCW NHS Trust
> > >> Clifford Bridge Road
> > >> COVENTRY
> > >> CV2 2DX
> > >>
> > >> Contact:
> > >> Tel (internal): 28952
> > >> Tel (external): +44 (0) 24 7696 8952
> > >> Email: [EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>
> > >> Web: www.uhcw.nhs.uk
> > <http://www.uhcw.nhs.uk>
> > >>
> > >>
> > >>
> > >>
> > >>
> > >>
> > >
> > >
> >
> >
> >
> > --
> > ** 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