Posted by JackpipE on 09/27/07 19:58
I need to create multidimensional array with arrays inside of it.
database
name | value1 | value2
john | red | 45
john | red | 56
john | yellow | 11
mike | blue | 23
mike | black | 41
I would like to get this in this array format:
Array ([john] => Array( [0]=>red [1]=>red [2]=>yellow) Array( [0]=>45
[1]=>56 [2]=>11))
The idea as you can see is to have value1 and value2 as separate array
within the name array.
Thanks,
Jack
Navigation:
[Reply to this message]
|