php - How to use FOUND_ROWS() on multiple tables -


i have following query executes without error, not return correct number of rows. same query works when selecting 1 table, not two:

select found_rows() `total`  `products` t1  right join `homepage` t2 on `t2`.id = `t1`.id; 

to row count this:

select count(*) `total`  `products` t1  right join `homepage` t2  on `t2`.id = `t1`.id; 

Comments

Popular posts from this blog

java - Spring Data JPA: Why findOne(id) executing delete query internally? -

python - Mongodb How to add addtional information when aggregating? -

java - Incorrect order of records in M-M relationship in hibernate -