MySQL : How to only select certain data from the table?

Hie All,

How do I only select a certain results from the table using MySQL queries?

Eg: I have a table below.

+-----------+
| data |
+-----------+
|      BM |
|      BI  |
|      MM |
|      SJ  |
|      GE |
|      PJ  |
+-----------+

How do I only select all the data except 'PJ' ?

Thanks.
LVL 1
bosscatAsked:
Who is Participating?
 
Kiran SonawaneProject LeadCommented:
Try like this
SELECT * from your_table_name where  data != "PJ"
0
 
bosscatAuthor Commented:
Awesome! it works. thanks alot and the prompt response.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.