tracker issue : CF-3649985

select a category, or use search below
(searches all categories and all time range)
Title:

Query of Query column alias ignored

| View in Tracker

Status/Resolution/Reason: Closed/Fixed/

Reporter/Name(from Bugbase): Bradley Wood / Bradley Wood (Bradley Wood)

Created: 10/15/2013

Components: Database

Versions: 10.0

Failure Type:

Found In Build/Fixed In Build: Final / 288354

Priority/Frequency: Major / Some users will encounter

Locale/System: English / Windows 7 SP1 64-bit

Vote Count: 0

Problem Description: Query of Query column alias ignored when column name is preceded by the name of the query

Steps to Reproduce:

<cfset qryName = queryNew("col")>

<cfquery name="qryResult" dbtype="query">
	SELECT qryName.col as aliasName
	FROM qryName
</cfquery>

<cfoutput>#qryResult.aliasName#</cfoutput>

Actual Result:

Error Occurred While Processing Request
Element ALIASNAME is undefined in QRYRESULT.

Expected Result:

No error.  Output empty string.

Any Workarounds:

Omitting the result set name like so will work.

<cfset qryName = queryNew("col")>

<cfquery name="qryResult" dbtype="query">
	SELECT col as aliasName
	FROM qryName
</cfquery>

<cfoutput>#qryResult.aliasName#</cfoutput>

However, that is not an option when joining to result sets with the same column name.  This worked in CF9 and is a regression in CF10.

----------------------------- Additional Watson Details -----------------------------

Watson Bug ID:	3649985

External Customer Info:
External Company:  
External Customer Name: bradwood.com
External Customer Email:  
External Test Config: My Hardware and Environment details:



Server Product	 ColdFusion

Version	 10,0,11,285437

Tomcat Version	 7.0.23.0

Edition	 Developer  

Serial Number	 Developer  

Operating System	 Windows 7  

OS Version	 6.1

Attachments:

Comments:

I think it may have been fixed. I ran this code and didn't get any errors when running it on ColdFusion 10,0,11,285380 Tomcat 7.0.23.0 JRE 1.7.0_15 (Windows 2012 R2 64bit)
Comment by External U.
14207 | October 15, 2013 02:59:35 PM GMT
@Jamo, You appear to be on update 11 too, but with a different build number. How did you come about that version? My CF Admin tells me I'm up-to-date.
Comment by External U.
14208 | October 15, 2013 03:12:07 PM GMT
@bradwood: I am not able to repro this issue. Can you please share more details about this issue?
Comment by Nimit S.
14209 | October 21, 2013 10:14:25 AM GMT
@Nimit No additional details are necessary. On my machine with the specs above the error happens every time. Can you confirm the update version of your installation that you are testing with. As you can see from @Jamo's comment, there appears to be an unreleased updater that might have fixed the issue.
Comment by External U.
14210 | October 21, 2013 10:36:48 AM GMT
*Some* additional details are clearly necessary, Brad, as I can't replicate this either. However it's probably more for Nimit to suggest what additional info might help, rather than leaving it to you to guess! Clearly, Nimit, this can happen - Brad's not one to lie or be mistaken - so you're gonna have to look at the relevant code and check what might be causing it. Simply saying "cannot replicate" ain't good enough. One thing I can think of... what JVM version are you on, Brad? For the record, I tested this on 10,0,11,285437, running Java 1.7.0_15. -- Adam
Comment by External U.
14211 | October 21, 2013 03:52:11 PM GMT
Adam, I too am on Java 1.7.0_15. I see you are using the exact same build of CF as I am so perhaps the updater version is a red herring. @Nimit, If you have any specific information you would like, please let me know.
Comment by External U.
14212 | October 21, 2013 07:07:04 PM GMT
@bradwood: I have tried it with basic ColdFusion build without any update or along with Update 11. I am not getting this issue. Would you mind sharing ColdFusion's settings summary at: nimsharm@adobe.com? @Adam: I am sure bradwood is not lying but I just wanted to know if there is any specific workflow which may be I am missing.
Comment by Nimit S.
14213 | October 22, 2013 02:13:31 AM GMT
Server settings E-mailed.
Comment by External U.
14214 | October 22, 2013 02:50:47 AM GMT
Update, Fusion Reactor being installed appears to be the missing key to reproducing the error. See this thread: https://groups.google.com/d/msg/fusionreactor/nsz_2Wy-bsU/XxJP5aMIdy0J
Comment by External U.
14215 | January 22, 2014 01:30:19 PM GMT
Gah! Refreshing the page after submitting a comment apparently resubmits the comment. Can someone from Adobe please remove my duplicate comment below.... and this explanatory comment :/
Comment by External U.
14216 | January 22, 2014 04:13:04 PM GMT
This issue is fixed in the next major release of ColdFusion.
Comment by Nimit S.
14217 | March 14, 2014 10:14:47 AM GMT