Here is the script to create my tables:
CREATE TABLE clients ( client_i INT(11), PRIMARY KEY (client_id) ); CREATE TABLE projects ( project_id INT(
Try this,
DELETE posts.* FROM posts INNER JOIN projects ON projects.project_id = posts.project_id WHERE projects.client_id = :client_id