Issues

Select view

Select search mode

 

SQL Comment is disabling further parameters

Unresolved

Description

I was trying exactly this query

The comment was a notation of myself to not wonder why later. I can (and should) move it outside the query.

However, when I ran it, I was getting "Incorrect syntax near ':'."

Simply removing the SQL comment caused the code to execute correctly. I'll move the comment anyway.

The part that I find most interesting is that I have other queries that seem to do this fine. I'll truncate this because it's huge. Although my other queries are one rather than two.

For what it's worth, according to CF Builder and Notepad++, the erring queries do end with carriage return and new line on each line (\r\n).

Environment

Lucee 5.2.6.59 -- Jira wouldn't let me select that.
Windows 10, IIS, SQL Server.

Details

Assignee

Reporter

Priority

New Issue warning screen

Before you create a new Issue, please post to the mailing list first https://dev.lucee.org

Once the issue has been verified, one of the Lucee team will ask you to file an issue

Affects versions

Created 14 March 2018 at 17:12
Updated 13 February 2023 at 13:32

Activity

Show:

Pothys - MitrahSoft13 February 2023 at 07:48

6.0 -
5.4 -
5.3 -

Ryan Mueller23 March 2018 at 01:33

Glad to see this prioritized as Major.
Thought I was losing my mind for a little while there.

Pothys - MitrahSoft16 March 2018 at 08:19

I've added test case for this ticket & confirmed the issue happened on lucee. If we use SQL comments in QueryExecute tag it throws error like "invalid syntax near ":" ". Without the queryparam value it working fine. In ACF working as expected.

Pull request : https://github.com/lucee/Lucee/pull/416

Flag notifications