Fixed a problem with integers being simplified to booleans and enabled
some simple Scala subquery and aggregation tests.