public function has($primaryKey, $column = null)
    {
        if (null === $column) {
            $column = $this->getPrimaryKey();
        }

        return (boolean)$this->app['db']->fetchColumn(
            'SELECT COUNT(:column) FROM ' . $this->getTable() . ' WHERE '.$this->getPrimaryKey().' = :pk',
            [
                'column' => $column,
                'pk' => $primaryKey
            ]
        );
    }