sql - What is the fastest way to pass database cell values to many different PHP variables? -


i have oracle database serves array of ~70 values. trying find efficient code pass each cell value variable, preferebly coded in php.

example:

cell1   cell2 cell3 cell4 ... cell70 

pass each cell 1-70 variable named after cell:

($cell1, $cell2, $cell3, $cell4 ... $cell70) 

it'd far simpler use array:

$arr = oci_fetch_array(...); 

so don't pollute namespace bunch of (mostly) useless variables.

if insist on going route, try:

list($cell1, $cell2, $cell3, ...., $cellwaytoomanycells) = oci_fetch_array(...); 

or

$arr = oci_fetch_assoc(...); extract($arr); 

Comments

Popular posts from this blog

javascript - RequestAnimationFrame not working when exiting fullscreen switching space on Safari -

Python ctypes access violation with const pointer arguments -