Added full implementation for DoctrineDbal as the query language, though in part based on the original Sql implementation.