title: Query returning null on a column with info
body: <p>I've got a few different tables, one is <code>hotel</code> and contains information in regards to a chain of hotels, and another is <code>room</code> which contains information about the rooms within the hotels.</p>
  
  <p>I'm trying to query the database for a list of the hotel names along with the room numbers ordered in a certain way. Ordering them is easy, but I've had trouble trying to hack up some code to make this work.</p>
  
  <p>What I've got is:</p>
  
  <pre><code>SELECT
      hotelName,
      roomNo
  FROM
      hotel
  RIGHT JOIN
      room
  ON
      hotel.hotelName = room.roomNo
  </code></pre>
  
  <p>This works, it joins the tables and presents all the room numbers but all the hotel names are returned as null. I've been working on this for a few days now, its part of my study, but I just can't work out how to get it to work. The tables aren't connected via and keys but as far as I can tell that shouldn't matter, and it didn't matter with the normal and LEFT JOIN's.</p>
  
  <p>Cheers for any help on this one guys :)</p>
  
  <p>This is the database presented in the designer on phpMyAdmin and the result I'm getting with the current code. The only difference I need is that the hotel name shows the actual hotel names stored in the database.</p>
  
  <p><a href="https://i.stack.imgur.com/WaWs6.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/WaWs6.png" alt="enter image description here"></a></p>