Hi there,
I have this data stored in arrays like below and I decided I wanted to store it in the
database instead.
Is my table a correct representation of the arrays, and if so, how do I pull the
data back out of the database, and still have it represent the way it was stored in the
arrays thanks
id| parent_id | date | user | text
1 | 0 | 2012/01/20 | Leon | Some text one
2 | 1 | 2012/01/20 | Brad | Some text two
3 | 0 | 2012/01/20 | Chris | Some text three
[php]$data = array
(
1 => array
(
“parent_id” => 0, “date” => “2012/01/20”, “user” => “Leon”, “text” => “Some text one”
),
2 => array
(
“parent_id” => 1, “date” => “2012/01/20”, “user” => “Brad”, “text” => “Some text two”
),
3 => array
(
“parent_id” => 0, “date” => “2012/01/20”, “user” => “Chris”, “text” => “Some text three”
)
);[/php]