src/Charcoal/Admin/Script/Object/Table/AlterPrimaryKeyScript.php
private function fetchTargetRows()
    {
        $model  = $this->targetModel();
        $source = $model->source();

        $sql = strtr(
            'SELECT %key FROM `%table`',
            [
                '%table' => $source->table(),
                '%key'   => $this->oldPrimaryKey(),
            ]
        );

        return $source->db()->query($sql, PDO::FETCH_ASSOC);
    }
private function fetchTargetRows()
    {
        $model  = $this->targetModel();
        $source = $model->source();

        $sql = strtr(
            'SELECT %key FROM `%table`',
            [
                '%table' => $source->table(),
                '%key'   => $this->oldPrimaryKey(),
            ]
        );

        return $source->db()->query($sql, PDO::FETCH_ASSOC);
    }
private function fetchTargetRows ( ) { $ model = $ this -> targetModel ( ) ; $ source = $ model -> source ( ) ; $ sql = strtr ( 'SELECT %key FROM `%table`' , [ '%table' => $ source -> table ( ) , '%key' => $ this -> oldPrimaryKey ( ) , ] ) ; return $ source -> db ( ) -> query ( $ sql , PDO :: FETCH_ASSOC ) ; }
Retrieve the target model's rows.

@return array|Traversable
Retrieve the target model s rows .