SQL error after migration Coldfusion to Lucee

51 views
Skip to first unread message

Pierre Larde

unread,
Sep 18, 2016, 2:24:05 PM9/18/16
to Lucee
This Query  is running fine Under Coldfusion 9

<cfquery name="list_quest" datasource="#forum_datasource#">
   select *,topic_titre,topic_group from questions
   inner join topics on topics.topic_id=questions.quest_topic_id
   where quest_topic_id=#url.topic_id#
   order by last_answer_date desc
 </cfquery>

with same code, same files, Running Under Lucee V4, I get this error :

Date : 17-Sep-2016   19:44:28
Erreur sur page :
/forumsite/topic.cfm
Query string :
topic_id=1
Diagnostic :
UCAExc:::3.0.3.1 duplicate column name in derived table
The error occurred on line 22 in file D:\SitesPlarts\C027\www\forumsite\topic.cfm.
IP adresse : 83.34.138.94
Visiteur non loggué.
Provenance (http_referer) :
http://chante-la-vie.fr/forumsite/start_forum.cfm
Navigateur : Mozilla/5.0 (Windows NT 5.1; rv:48.0) Gecko/20100101 Firefox/48.0

Cause :
lucee.runtime.exp.DatabaseException


A duplicate Column name  in derived table

Looking at the 2 tables : Topics and Questions

all fields have different names.


I do not understand, why I have this error,

and why this running under CF, does not under Lucee.


Thanks for any help.

Help for migration from CF to Lucee.

Pierre.

Nando Breiter

unread,
Sep 18, 2016, 3:15:38 PM9/18/16
to lu...@googlegroups.com
Pierre,

Perhaps if you change the select statement to simply 

select *

instead of 

 select *,topic_titre,topic_group

it would work. Lucee may be duplicating the columns topic_titre and topic_group




Aria Media Sagl
+41 (0)76 303 4477 cell
skype: ariamedia

--
Get 10% off of the regular price for this years CFCamp in Munich, Germany (Oct. 20th & 21st) with the Lucee discount code Lucee@cfcamp. 189€ instead of 210€. Visit https://ti.to/cfcamp/cfcamp-2016/discount/Lucee@cfcamp
---
You received this message because you are subscribed to the Google Groups "Lucee" group.
To unsubscribe from this group and stop receiving emails from it, send an email to lucee+unsubscribe@googlegroups.com.
To post to this group, send email to lu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/lucee/6b1c15c8-0da6-4da6-9660-eee1943b7f4e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Pierre Larde

unread,
Sep 18, 2016, 3:28:10 PM9/18/16
to Lucee
No, problem, the Forum datasource was not declared,
so this same query does work fine.

Just that the error message is not meaningful, talk about duplicated key,
but the datasource was missing.

The problem is solved.
Thanks,
Pierre.
Reply all
Reply to author
Forward
0 new messages