1 Reply Latest reply on Feb 12, 2007 6:33 AM by Dan Bracuk

    Multiple Select Error - Please Help!


      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>

      <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 "">
      mBASectorID in (#ListQualify(Form.mbasectorid,"'")#) </cfif>

      [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.