Hi
I am using a query below for a multiple select and it is giving me the error below. I am supposed to use the IN statement below but it still is giving me this error. I have been at this for days and it's driving me mad.
<select multiple="multiple" name="mbasectorid">
<option value="">All</option>
<cfloop query="qMBASectorSelect">
<option value="#qMBASectorSelect.MBASECTORid#"
<cfif qMBASectorSelect.MBASECTORid eq form.mbasectorid>
selected
</cfif>
>#qMBASectorSelect.MBASECTORName#</option>
</cfloop>
</select>
<cfquery name="qCVBookSelect" datasource="#request.dsName#">
select CVBook.CVBookID ,
CVBook.MBASectorID ,
MBASector.MBASectorName ,
:
:
from CVBook
left join MBASector on MBASector.MBASectorID = CVBook.MBASectorID
where 1 = 1
<cfif form.mBASectorID eq "">
and
mBASectorID in (#ListQualify(Form.mbasectorid,"'")#) </cfif>
</cfquery>
Error:
[Macromedia][SQLServer JDBC Driver][SQLServer]Syntax error converting the varchar value '1,2,3' to a column of data type int.
I would really appreciate anyones help.
Jennifer
I am using a query below for a multiple select and it is giving me the error below. I am supposed to use the IN statement below but it still is giving me this error. I have been at this for days and it's driving me mad.
<select multiple="multiple" name="mbasectorid">
<option value="">All</option>
<cfloop query="qMBASectorSelect">
<option value="#qMBASectorSelect.MBASECTORid#"
<cfif qMBASectorSelect.MBASECTORid eq form.mbasectorid>
selected
</cfif>
>#qMBASectorSelect.MBASECTORName#</option>
</cfloop>
</select>
<cfquery name="qCVBookSelect" datasource="#request.dsName#">
select CVBook.CVBookID ,
CVBook.MBASectorID ,
MBASector.MBASectorName ,
:
:
from CVBook
left join MBASector on MBASector.MBASectorID = CVBook.MBASectorID
where 1 = 1
<cfif form.mBASectorID eq "">
and
mBASectorID in (#ListQualify(Form.mbasectorid,"'")#) </cfif>
</cfquery>
Error:
[Macromedia][SQLServer JDBC Driver][SQLServer]Syntax error converting the varchar value '1,2,3' to a column of data type int.
I would really appreciate anyones help.
Jennifer