public function pluck(string $column, string $keyBy = ''): array
    {
        $pdoStatement = $this->provideStatement();
        $pdoStatement = $this->execute($pdoStatement);
        $rows = $pdoStatement->fetchAll(\PDO::FETCH_ASSOC);
        if (empty($rows)) {
            return [];
        }
        if (!isset($rows[0][$column])) {
            throw new DatabaseException('Column not found in result.');
        }
        if (!empty($keyBy) && !isset($rows[0][$keyBy])) {
            throw new DatabaseException('Column to use as key not found in result.');
        }
        $indexKey = (!empty($keyBy)) ? $keyBy : null;
        return array_column($rows, $column, $indexKey);
    }