Can't execute query

select * from messages LEFT JOIN categories_msg_tree tree ON tree.proId = messages.id where id =   AND lang = 'tw'

MySQL Error:

This script cannot continue, terminating.