AnsweredAssumed Answered

No suitable function overload for '=' could be found.

Question asked by GregMcFarlane on Jan 7, 2020
Latest reply on Jan 17, 2020 by gregor

I have a query that is throwing a weird error in SQL COMMANDER LITE

The line   'ea.value= '123456'  is throwing the error in the question title.


If i remove that line, i get a result set.

The result set has the column and some of the rows have the value requested in the omitted filter. 

Note that this attribute is a string

Note also that I am changing the name of the field to [AttrValue]. Removing this alias does not clear the error 



, s.MeanTemp, s.AirPressure, s.AirTemp, s.InjectionRate
        SELECT e.ID, e.Name, e.Template, e.PrimaryPath    
        , ea.Name [AttrName], ea.Value [AttrValue]   
        FROM [Master].[Element].[Element] e    
        join  Master.Element.Attribute ea on e.ID  = ea.ElementId     
        and ea.Name like 'CLASS No.' 
        WHERE  1=1    
        and e.Template = N'Engines'  
        and e.Name = N'EquipName'   
         and ea.value = N'123456'      <<<<<<====================
        CROSS APPLY [Master].[Element].[tvfMPDE_FuelInjector_GetSampledValues] 
        (   e.ID  
          , '5/1/2019'   
          , '5/31/2019'   
          , '1d'