Jump to content

How to store multidimensional array in database?


rahulephp

Recommended Posts

Hi there,

 

can you please help me?

 

i have data in array and i want to insert it in a single table.

structure of table and array to be store is shown below:

 

Please let me know how to store this array in database?

 

Database Structure:

database-structure.png

 

array-structure

arra- structure.jpg

 

database-Browse

database-Browes.png

 

Let me know any solution for this?

Thanks in anticipation

hi

 

change all fields to allow text characters and serailize the array:

 

$array = array ( 
    'temp_property_name' => array (
                                                 0=>'x',
                                                 1=>'y'
                                               )
                        );


$temp_property_name = serialize ( $array['temp_property_name'] );

 

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.