Which version (Standard, Enterprise, Developer) and release (9, 10, 11) of CF are you using, and on what OS?
Also, what is the entire JDBC connect string you are using?
I am using CF9 on Linux OS and trying to connect to SQL Server 2012 Alwayson.
my DSN created with build in driver always gets time out in the next day. but the DSN which i have created with the below URL, works fine.
below is the JDBC URL i am using.
ColdFusion 9 does not support SQL Server 2012, please check the support matrix, the CF 9 was tested and verified for SQL 2012 server.
I think Priyank meant to say that CF9 was tested and verified for SQL Server 2008 and only if you are using the Adobe-provided DataDirect drivers. If you are using Microsoft's JDBC drivers, especially the SQL Server 2012 version, you are on your own - that is not a configuration that Adobe will provide you support for.
Ohhh sorry it was a typo... Thanks Carl. Yes it is not supported with CF 9.
ohh..ok its fine..
I am able to connect to the SQL Server 2012 with the Microsoft drivers but I am getting extra spaces for the all the data which i retrieve data from DB, Do you know any idea why its happening or is there any way to fix it.
i have tried to write a query of quries to trim the data but QoQ is not working and throwing the error.
The same issue is happening with the 2008 ver too.
"Error","jrpp-30","06/27/14","07:26:52","Quotes","Query Of Queries runtime error.Unsupported SQL type java.sql.Types.UNKNOWN. The specific sequence of files included or processed is: /opt/coldfusion9/apps/www/redirectindex.cfm, line: 38 "
coldfusion.sql.imq.ImqUnsupportedSQLTypeException: Query Of Queries runtime error.
at cfingres2ecfm573751271$funcTRIMQUERY.runFunction(/opt/coldfusion9/CustomTags/ingres.cfm:3 8)
I have verified the datatype and i see that all the basic datatypes only.
What is the actual datatype of the fields that are getting extra spaces? Are they char(x) or nchar(x)? If so, that is to be expected as they are fixed-width fields (automatically space padded on the right side).
I don't think Query of Query (QoQ) supports the "trim" command, which might be why you get the error above. If the fields are char(x) or nchar(x), then you can use the SQL trim command into your initial query to remove the whitespace.
yes, the fields are char(x) and nchar(x) fields.
we have many files/modules which is difficult to put trim, so we are calling custom tag and trying to trim the data.
we are passing the query to customer and executing the query in custom tag with cfquery and trying to do trim by using the QoQ as it trims the data.
1 person found this helpful
Again, I don't believe QofQ supports the Trim function. In fact, the only place Trim appears on the QofQ page in Adobe docs is to indicate it is a reserved word and shouldn't be used.
As far as I can see, you only have two choices here: modify your database queries to use TRIM before running your QofQ, or change the database colums from char(x) and nchar(x) to varchar(x) and nvarchar(x). Unless this or other applications are relying on fixed character length fields, switching to varchar(x)/nvarchar(x) shouldn't result in any data loss or adverse side effects.