good day all!

I have quite an elusive little bugger that is really throwing me through
the hoops.

I have 2 queries on a page, that return about 25-30 rows apiece.

at one point, I have to make some other queries happen to get some
ancillary data
from another table (no a join wont suffice, makes the first query run
too long, anyway...)
I have this part of my code that write the value of one of the columns
into a variable name
that I called "routeName", I could throw queryName.routeName into the
display however sometimes
a parameter that I need to user to run a query to discern routeName,
isnt there, so instead
of just assuming that queryName.routeName may/may not be defined, I do
an if statement
block that check the existence, and if not, sets the value to null, so
that it I just get a space
in the csv file.  no problem.  

the problem is all things are there and defined, and show up from the
query, but for some
reason, the value isnt getting written.  im just getting nothing there,
I know the code
is written well, I know that the code works, its just like the server is
holding a null value in the
field from a previous iteration of the loop.

what var scope should I use here in this instance....

here is the cfif block to check for the existence of the needed
parameter to make the query...

<cfif isDefined("ReportWriterOld.driverId") and
isNumeric(ReportWriterOld.driverId)>
                
        <cfquery name="getRouteName" datasource="#myDS#" maxrows="1">
                select name, narcReady, toteReady, outpatientReady,
lateBy 
                from routes 
                where beginTime <= #timeIdAdj# and (endTime >=
#timeIdAdj# or endTime is null)
                and dId = #ReportWriterOld.DriverId#
        </cfquery>

        <cfset routeName = "#getRouteName.name#">               
                                
<cfelse>

        <cfset routeName = "No driver Id (old)">
                        
</cfif>


it's the spots where I set route name, that im wondering what scope to
make them?

thanks!

tony weeg
uncertified advanced cold fusion developer
tony at navtrak dot net
www.navtrak.net
410.548.2337

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq

This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.
http://www.cfhosting.com

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to