introduced named queries, not all transformed to named queries yet.
fixed branch hopefully