SQL query builder for PHP based on PDO