getting to grips with db interaction

Using xpdo or more familiar  $this->modx->query()