I am new to this community but if my question doesn't follow the rules, please feel free to close this. Thanks!
This is my php database query
$sql = "
SELECT meta_key
, meta_value
FROM " . $wpdb->prefix . "postmeta
WHERE post_id = " . $value->post_id . "
AND meta_key LIKE '_field_%'";
This is the output so far
| meta_key | meta_value |
| --------- | ---------- |
| _field_11 | Rosenie |
| _field_30 | Tagarda |
| _field_12 | Talibo |
| _field_11 | Rondeo |
| _field_30 | Soroysoroy |
| _field_12 | Balos |
But I want it to be like this
| _field_11 | _field_30 | _field_12 |
| ---------- | ---------- | --------- |
| Rosenie | Tagarda | Talibo |
| Rondeo | Soroysoroy | Balos |
Is there anyway to do this? Thanks in advance.
My temporary solution: https://pastebin.com/e5rF3ZQe