added getSingleScalarResult