WIP: converting to Hasql