Added elementary queries and unit tests