Update PVDatabase.php

Fixing order of group by in preperated selected