
parham_m_s
journeyman
Jun 28, 2001, 8:19 AM
Post #1 of 3
(2305 views)
|
i've selected, prepared, and executed my mysql statement... now what i want to do is push everything into an array because i don't want to drastically change my code from what it used to be, deliminated with pipes. i came up with this code (which is kinda what i want):
$data = $sth->fetchall_arrayref; #grabs all the data and puts it into an array foreach $row (@$data){ #now how do i split $row into each column?? this is what i theoretically think will work... ($id,$name,$explain,$question,$yes,$no) = $row->fetchrow() } are my handles right?, is there a different way i should be splitting my rows? I kinda haven't solved the problem, what i want to do is push each row into an array with columns separated with |'s (pipes)... any help?
|