Fix syntax of querying uploads