You could use and EXISTS in you case statement rather than an =
Not sure if I've got you logic right, but something like the following
-- Some Test Data
;with Fact as (
SELECT *
FROM (VALUES (1), (2), (3), (4), (5)) AS Fact(VisitID)
)
, Error as (
SELECT *
FROM (VALUES (1,'a'), (3,'w also has another'), (3,'a'), (4, 'w just this one'), (5,'a')) AS Error(VisitID, [Message])
)
-- The Query
SELECT f.VisitID, CASE
WHEN EXISTS(SELECT 1 FROM Error e WHERE e.visitID = f.visitID and [Message] not like 'w%') THEN 'false'
ELSE 'true'
END
FROM Fact f