Try
<cfquery name="update_funds" datasource="#request.dsn#">
insert into fundprevious
{
thisday,
fundid,
fundvalue,
timeofchange
}
values
{
#thisfundday#,
#get_funds.fundid#,
'#previousValue#',
#CreateODBCDate( Now())#
}
</cfquery>
-----Original Message-----
From: David Ashworth [mailto:[EMAIL PROTECTED]
Sent: 22 March 2004 11:29
To: CF-Talk
Subject: db error
Morning,
I keep getting the following error when trying to update a database,
haven't had any problems when doing this before but this error is
peristent and I can't work out what the problem is:
It appears to be a problem with the query as opposed to the data, the
query is as follows:
<!--- save current value into previous value --->
<cfquery name="update_funds" datasource="#request.dsn#">
insert into fundprevious
{
thisday,
fundid,
fundvalue,
timeofchange
}
values
{
#thisfundday#,
#get_funds.fundid#,
'#previousValue#',
#Now()#
}
</cfquery>
which gives this error:
ODBC Error Code = 37000 (Syntax error or access violation)
[Microsoft][ODBC SQL Server Driver]Syntax error or access violation
SQL = "insert into fundprevious { thisday, fundid, fundvalue,
timeofchange } values { 1, 3, '5', {ts '2004-03-22 11:28:38'} }"
Data Source = "FUNDMANAGER"
The error occurred while processing an element with a general identifier
of (CFQUERY), occupying document position (27:2) to (27:57) in the
template file
D:\INETPUB\WWWROOT\FUNDMANAGER\ADMIN\FUND\ACT_UPDATESTOCK.CFM.
any thoughts?
_____
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

