Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

On array How can i select only column

Array
(
[0] => Array
(
[table] => form_identification
[column] => region
)

[1] => Array
    (
        [table] => form_identification
        [column] => province
    )

)

The output will be like this

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

Array
(
[0] => Array
(
[column] => region
)

[1] => Array
    (
        [column] => province
    )

)

Thankyou

>Solution :

Hey welcome to stack overflow,

Consider your first array as $datas variable here and we are using for each whole array

foreach($datas as $data) {
    $result[] = array('column' => $data['column']);
}
print_r($result);
Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading