Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Query Of Query Conversion Problem

Status
Not open for further replies.

cfhelp

Programmer
Jan 11, 2006
11
US
Hi,
I recently upgraded to coldfusion MX 7. I have the following Query of Query Problems.
The database is SqlServer.

i.I have an integer column, where i try to change the value to a character.

<cfset temp = QuerySetCell(Attributes.Query,trans_col_name,trans_value)>
trans_col_name - is an integer column in the table which has a value of 3.
trans_value - a hardcoded value "RS".

I get the following error
'Invalid data RS for CFSQLTYPE CFSQLBIGNINT'.


ii.I am trying to format a date.
Value before formatting is 2005-10-20 15:16:06.0
After formatting is 2005-10-20 00:00:00.0
This is a datetime field in the table, below is my code.

<cfquery name="cq_msg" datasource="#Request.DataSource#">
Select
msg,
msgkind,
msgwarn,
add_time
from D_MESSAGE
WHERE
msg = '100'
</cfquery>

<cfset FtmtDate = DateFormat("#cq_msg.add_time#", "MM/DD/YYYY")>
<cfset temp = QuerySetCell(cq_msg, "add_time", FtmtDate, 1)>

Any help or suggestion is greatly appreciated.
Thanks





 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top