June 3, 2005 at 3:34 am
Doesnt like this... as more than 1 value is returned.. can u somehow combine a LIKE with an IN?
SELECT CASE
WHEN
(SELECT Name
FROM Rooms
WHERE Event_Type = 'aa')
LIKE '%Cinema 1%'
THEN 'b'
(partial code)
etc etc
June 3, 2005 at 3:44 am
Something like:
SELECT CASE
WHEN EXISTS
(SELECT *
FROM Rooms
WHERE Event_Type = 'aa'
AND name LIKE '%Cinema 1%')
THEN 'b'
June 3, 2005 at 4:01 am
brilliant, thanks again chris!
June 3, 2005 at 5:50 am
maybe I'm missing something here, but unless you corellate the subquery, you will get the same value for the whole resultset... is that what you want?
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply