You have several rows, but you want to look at a set of rows. This is called aggregation. In your case you want to look at each room chat, so you group by room_chat. You want to know whether for a room chat you find both names, so count the names.

The query:

select room_chat
from table
where name in ('Ratna','Ima')
group by room_chat
having count(distinct name) = 2;

Email codedump link for MySQL select one row from field WHERE condition is in multiple rows