Select result
from:

I want to pass the result of select into an array, I using PDO.

function listar(){ $query = "SELECT codigo, nombres FROM prueba"; $BD = new ConexionDB(); $recordSet = $BD->prepare($query); $recordSet->execute(); // In this part I need help. // This part is a old code I need to change this parte. $lista = array(); while($fila=$recordSet->FetchRow()) { $lista[] = new PruebaVO($fila['codigo'], $fila['nombres']); }... PHP:

Select result

Poster :
piropeator