Hi there
Got a query here which I do not understand.
I'm doing two queries,
<!--- query one --->
<cfquery name="qry_getCustReporta"
datasource="#application.dsn#"
username="#application.gateway#"
password="#application.key#" maxrows="1">
SELECT min(flow1) as mflow1,
datepart(dd, dt) as day,
datepart(mm, dt) as month,
datepart(yy, dt) as year
FROM dbo.milford
WHERE flow1 > -0.01
AND
datediff(day, dt, getdate()) = 0
GROUP BY datepart(dd, dt), datepart(mm, dt),
datepart(yy, dt)
</cfquery>
<!--- query two --->
<cfquery name="qry_getCustReport"
datasource="#application.dsn#"
username="#application.gateway#"
password="#application.key#" maxrows="1">
SELECT dt, flow1
FROM dbo.milford
WHERE flow1 = #qry_getCustReporta.mflow1#
AND
flow1 > -0.01
AND
datediff(day, dt, getdate()) = 0
</cfquery>
OK
The result from the first query is
<cfoutput>#qry_getCustReporta.mflow1#</cfoutput> which = 26.649746192893399
the result from the second query is (by the way I'm doing this to get the
time stamp)
<cfoutput>#qry_getCustReport.dt#</cfoutput> which = 2001-07-04 04:30:01
this works on my development server
but when I run it on the live server
<cfoutput>#qry_getCustReporta.mflow1#</cfoutput> becomes rounded
automatically to 26.65
so when I try to run the second query I obviously get a blank result for
<cfoutput>#qry_getCustReport.dt#</cfoutput>
I'm using sql server 7.0 and flow1 has a datatype of (float 8)
Cheers for any help anyone is able to give on this one.
John.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists