Hi everybody
I am trying to use queries in access(2K) as SP.
I can get all to work but dates.
If I hard code dates in the query like: #1/15/2003# the correct records
are returned.
Just can't get it to work with:
<cfstoredproc procedure="sp_supplycosts" datasource="#Session.dsn#"
dbtype="ODBC">
<cfprocparam type="In" cfsqltype="CF_SQL_DATE" dbvarname="itemdate"
value="#CreateODBCDate(form.itemdate)#" null="No"> <CFprocresult
name="Qgetsupply">
</CFSTOREDPROC>
This doesn't error, but also doesn't return any records.
I have tried placing the #s around the var in the query, but Access doesn't
like that.
I have tried
<cfprocparam type="In" cfsqltype="CF_SQL_DATE" dbvarname="itemdate"
value="###CreateODBCDate(form.itemdate)###" null="No">
which gets me the error:
Microsoft][ODBC Microsoft Access Driver]Invalid character value for cast
specification (null)
I have tried:
<cfprocparam type="In" cfsqltype="CF_SQL_VARCHAR"
dbvarname="itemdate" value="###dateformat(form.itemdate, 'mm/dd/yyyy')###"
null="No">
which sends the date as: #1/15/2003# to the query, again no error, but no
records.
The format of the date field is Short Date mm/dd/yyyy.
Using:
CF5
WIN2K
Access 2K
Any help would be appreciated.
TIA
Rodney
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
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
Get the mailserver that powers this list at http://www.coolfusion.com
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4