I have this table structure: http://www.dropmocks.com/mBjNvF and need to get the id_user_rq if not exists in id_user_ap as the title said. I need to get the rows where id_user_rq = 1 and id_user_ap = 2 and id_user_rq = 2 and id_user_ap = 1 meaning that I send a invitation and the other part accept me and inverse the relation, any help?
Mysql – Get the rows where id_user_rq exists in id_user_ap and viceversa
MySQLquery
Related Question
- Mysql – How to select/count rows where the same value exists in a column but not in other column all at the same table
- Mysql – Get the id_user_app if not exists in id_user_rq
- Get Rows Where lastLoginTimestamp is in the Last 7 Days in MySQL
- MySQL – How to Select Rows Where Condition Exists
- Mysql – Return “parent” rows where only one “child” record exists in one-to-many relationship
- Mysql – Finding rows in a table with a foreign key pointing back at itself where the referenced row differs in a certain column
Best Answer
Please try this: