|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Stay one step ahead of the competition. Evaluate and give feedback
on some of the hottest web development tools on the market today.
Make your opinion heard! Click
Here
|
|
#1
|
|||
|
|||
|
select date type from Oracle table in ColdFusion
Hi. I am trying to run a query in ColdFusion that includes a date data type. If I run the query in SQL+ I can see the date value but when I run the query from a ColdFusion page the date value is always an empty string.
Here is how I am inserting the date value: Code:
<cfquery name="my_query" datasource="my_datasource"> insert into MY_TABLE (MY_DATE_FIELD) values (<cfqueryparam value="#now()#" cfsqltype="cf_sql_date" />) </cfquery> I run a query like this to try and get the date value: Code:
<cfquery name="my_query" datasource="my_datasource"> select MY_DATE_FIELD from MY_TABLE </cfquery> What am I doing wrong? Thank you for your help. |
|
#2
|
|||
|
|||
|
now() does not return a valid ODBC date type. Try inserting the date by using the createODBCDate() function.
|
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ColdFusion Development > select date type from Oracle table in ColdFusion |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|