select *
from persons p join quantity q on p.id = q.people_id
join books b on q.product_id = b.id
More Related Contents:
- SELECT POPULAR POST
- How to filter SQL results in a has-many-through relation
- Return row only if value doesn’t exist
- How to fix: “No suitable driver found for jdbc:mysql://localhost/dbname” error when using pools? [duplicate]
- UTF-8: General? Bin? Unicode?
- Transposing Dynamic Columns to Rows
- Are nested transactions allowed in MySQL?
- LOAD DATA INFILE easily convert YYYYMMDD to YYYY-MM-DD?
- MyIsam engine transaction support
- When to use SELECT … FOR UPDATE?
- BULK INSERT in MYSQL
- Setting column values as column names in the SQL query result
- Count table rows
- MYSQL sum() for distinct rows
- Implementing a hierarchical data structure in a database
- How to lock a single row
- MySQL Cannot drop index needed in a foreign key constraint
- How to get current date & time in MySQL?
- Laravel join with 3 Tables
- MySQL Insert & Joins
- phpMyAdmin – can’t connect – invalid setings – ever since I added a root password – locked out
- How to join two tables using a comma-separated-list in the join field
- How do I split the output from mysqldump into smaller files?
- How to regex in a MySQL query
- How to remove duplicate entries from a mysql db?
- Syntax error on MERGE statement
- How do you force mysql LIKE to be case sensitive? [duplicate]
- MySQL Alter table causes Error: Invalid use of NULL value
- Delete all rows with timestamp older than x days
- In what order are MySQL JOINs evaluated?