跳至主內容

搜尋

搜尋

Custom Sql Odbc Error

評論

3 條評論

  • Avatar
    Legacy Poster

    When using an ODBC connection, it shows an error but it does not save the query.

     

     

    This is only happening for DSNs.  When I connect directly from BarTender using SQL Server OLE DB, I get an error message, but BarTender saves the custom query.

    0
  • Avatar
    Legacy Poster

    I made a change to the stored procedure to check if the value passed is numeric.  If the value is not numeric it defaults to 0 then returns an empty result set.  Doing this prevents the SP from bombing on the conversion of the passed BarTender string parameter to integer.

     

    Here is the workaround.. Not very elegant, but it works..

     

     

     

    WHERE ID =  CASE WHEN IsNumeric(@Param) = 1 THEN @Param ELSE 0 END
    
    0
  • Avatar
    Shotaro Ito

    Thanks nhadley, for sharing the workaround!

    0

登入寫評論。