rename parameters to make autocomplete work easier in some cases
move helper method to PoddSesameRealm and optimise it and other queries

some queries were running over the entire database, so hopefully fixing
that with new code
pass through illegalstateexception that we create locally without
wrapping it up