table :First
..............................................................................
id | ros | table | column | stool | date | places|
..............................................................................
1 12 5 6 a 2017-07-17 goa |
2 12 5 6 b 2017-07-17 delhi|
..............................................................................
table :second
..........................................................................
id | ros | name | email | phone | stos|address |date |
....................................................................................................
5 12 and and@her.com 394924673464 6 fddsfds 2017-07-03 |
6 12 her her@and.com 84838593894 6 fdafdfd 2017-07-04 |
....................................................................................................
Query like I am Using:
SELECT `p`.* FROM `first` `p` LEFT JOIN `second` as `st` ON `st`.`ros`=`p`.`ros` ORDER BY `id` DESC LIMIT 10;
My question is why it returns 4 rows instead of just 2? its resturning 4 value without having in the table should i need to use distinct or group by for that ??