Craig,
I've just tried importing to SQL 7, but the problem here is that when
importing the data I lose the RATE function.
My code is updating the spreadsheet successfully every time. Its only when I
go to read the new value (I'm simply using the sheet for apr calculation
purposes) that I am getting a consistently cached value.
Thanks for your suggestion though,
Dave
-Original Message-
From: Craig Thomas [mailto:[EMAIL PROTECTED]]
Sent: 18 April 2002 14:18
To: CF-Talk
Subject: RE: Strange behaviour with excel datasource
I have had this problem too (with CF 4.5). I was able to read from the
excel data source alright and even update values (once). Then subsequent
reads used the OLD value and updates were no longer happening. I wish I
could remember the details of the investigation, but we ended up importing
the excel file into a SQL server 7 database and using it as the data source.
Craig
-Original Message-
From: Dave Wilson [mailto:[EMAIL PROTECTED]]
Sent: Thursday, April 18, 2002 8:52 AM
To: CF-Talk
Subject: Strange behaviour with excel datasource
Hi all,
I'm running two consecutive queries on an excel datasource as follows:
first query simply updates values in a single record in the spreadsheet. The
spreadsheet then uses these values to calculate APR on a loan using
successive approximations method (RATE function in excel).
The second query is a select statement in order to extract the resulting
APR.
Fairly straightforward, however the second query seems to always only
retrieve a cached result.
I've unchecked the maintain datasource connections in the datasource
settings and have even tried using cachedwithin=createtimespan(0,0,0,0) in
my cfquery tag, yet I'm still having a cached result being returned.
My code is below:
cfset loan_amt = ((vehicleadj + optionadj) * #variables.quantity#) -
depositadj - balloonadj - tradeinadj
cfquery name=enter datasource=finance maxrows=1
UPDATE APR$
SET payments = #quotation.term#,
payment_amt = -#monthlyadj#,
loan_amt = #loan_amt#,
guess = #quotation.apr#/100
WHERE marker = 1
/cfquery
cfquery name=get datasource=finance maxrows=1
cachedwithin=#createtimespan(0,0,0,0)#
SELECT Rate
FROM APR$
WHERE marker = 3
/cfquery
cfset apradj = get.rate * 100
Any ideas welcome.
TIA
Dave
__
This list and all House of Fusion resources hosted by CFHosting.com. The place for
dependable ColdFusion Hosting.
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists