question

ggojra avatar image
ggojra asked

it says something is wrong in the last line. i cant figure it out

SELECT cname
FROM car
WHERE (serial) IN
(SELECT serial
FROM baseoption
WHERE ocode IN
(SELECT ocode
FROM options
where ODESC like='%Sun roof&';
sqldatabasemysql
10 |1200 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

· Write an Answer
WRBI avatar image
WRBI answered

There is no need for the = sign in the like.

-- Yours
where ODESC like='%Sun roof&';

--Should be

where ODESC like '%Sun roof&';

Also, should it be roof& or roof%?

Regards

WRBI

10 |1200 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.