MySQL Forums
Forum List  »  Newbie

Re: help with mysql query's
Posted by: Ramalingam Chelliah
Date: April 17, 2005 10:18PM

Hi,
Could you give the complete schema?

Refer this page for pattern matching
http://dev.mysql.com/doc/mysql/en/pattern-matching.html

i)
SELECT * FROM
Employee
WHERE name LIKE '%T%' AND jobtitle='salespeople' OR jobtitle='clerk' ;

ii)
SELECT name,jobtitle FROM
Employee
WHERE JoinDate > '1991-06-30' AND jobtitle != 'salespeople' AND jobtitle != 'clerk' ;

I hope this helps

If date comparision doesn't work properly, look for Date functions in the MySQL Online document


Regards,
Ram.

We Learn the Most When we have to Invent

Options: ReplyQuote


Subject
Written By
Posted
d d
April 17, 2005 01:51PM
Re: help with mysql query's
April 17, 2005 10:18PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.