
	SELECT project.id AS the_project FROM project
	LEFT JOIN client ON client.id = project.client
	LEFT JOIN academic_position ON academic_position.id = client.academic_position
	WHERE
	(
		project.academic IS NULL
		OR
		project.academic = ''
		OR
		(project.academic = 'Yes' AND seniority = 'Non-Academic')
		OR
		(project.academic = 'No' AND seniority <> 'Non-Academic')
	)
	AND	client.id <> 6227
	AND project.id > 12852
