How should I format my code to make it easier to read and understand in the future I am using this query to generate a conversation stream between user 184 and 192-    

SELECT events.event_time, messages . *
FROM   events , messages
WHERE  events.global_id=messages.global_ref_id  AND 
       (messages.to =184 AND messages.from =192) OR
       events.global_id=messages.global_ref_id AND
       (messages.to =192 AND messages.from =184) AND 
       messages.global_ref_id &lt; 495
ORDER BY `messages`.`global_ref_id` ASC


This query is working good for generating conversation between two users.
Can you help me with converting this query to something more readable. Because I believe it is just a workaround and will cause some problems in future.
Schema of messages table

Field         Type    
global_ref_id int(12)
to            int(12)
from          int(12)
message       text    
status        int(1)
viewed        int(1)


where global_ref_id is foreign key.
I prefer using JOIN...ON, clarifying an intention of priority of OR and AND phrase.

SELECT
  events.event_time,
  messages . *
FROM
  events
  JOIN messages ON events.global_id = messages.global_ref_id
WHERE
    ((messages.to =184 AND messages.from =192)
      OR (messages.to =192 AND messages.from =184))
    AND messages.global_ref_id &lt; 495
ORDER BY
  messages.global_ref_id ASC