I've been looking at this statement for ages and I'm sure its something minor. However I cannot get it to pull the data through via VBA. Strange thing is it works in SQL as a statement but as soon as I run it through VBA I get a runtime error. I could really do with a second pair of eyes.
stSQL = "EXEC('SELECT T1.Name FROM [dbo].[Tbl1] T1 " & _
"INNER JOIN [dbo].[Tbl2] T2 ON T1.ID = T2.ID " & _
"WHERE T2.NAME = '" & sBizUnit & "' AND Desc = '''' ORDER BY Name')"
sBizUnit is a value from a combobox:
sBizUnit = CB_BizU.Value
Thanks in advance