How To Query Two Words?

Hi,

I have the following code which will query against one word. In this example the word is ‘Host’. However I am trying to make it query against two words. The second one being ‘Organiser’. I have tried a few options like OR and , but whatever I try doesn’t seem to work. Any suggestions please?

When I try Organiser on its this works but I cant work out how to query them together.

<?php
$query = mysql_query("SELECT dealcompany, logo, ID, dealcountry, eventid, dealdescription, dealtitle, company, country, usertype, state
FROM users
JOIN deals ON deals.userid = users.id
WHERE deals.dealtypeowner = 'Host' ORDER BY eventid DESC LIMIT 10"); 											
																		
while($row = mysql_fetch_array($query)) {
	  ?>
<?php
$query = mysql_query("SELECT dealcompany, logo, ID, dealcountry, eventid, dealdescription, dealtitle, company, country, usertype, state
FROM users
JOIN deals ON deals.userid = users.id
WHERE deals.dealtypeowner = 'Host' OR 'Organiser' ORDER BY eventid DESC LIMIT 10"); 											
																		
while($row = mysql_fetch_array($query)) {
	 
	  ?>

OR links two independant conditions.
Look at it this way and it may make more sense:

SELECT dealcompany, logo, ID, dealcountry, eventid, dealdescription, dealtitle, company, country, usertype, state
FROM users
JOIN deals 
ON deals.userid = users.id
WHERE deals.dealtypeowner = 'Host' 
OR 'Organiser' 
ORDER BY eventid 
DESC LIMIT 1

Note that the “OR” line doesnt make much sense. It just says “Organiser”.

Try this:

SELECT dealcompany, logo, ID, dealcountry, eventid, dealdescription, dealtitle, company, country, usertype, state
FROM users
JOIN deals 
ON deals.userid = users.id
WHERE deals.dealtypeowner = 'Host' 
OR deals.dealtypeowner = 'Organiser' 
ORDER BY eventid 
DESC LIMIT 1

If you start adding more options, you might want to use field IN(‘A’,‘List’,‘Of’,‘Words’) instead of field = ‘A’ OR field = ‘B’ OR…