How to assemble the same elements of an array together

there is an array of the first picture below. I want to assemble the same parts of the time Y-m-d together. Is there any other way that I use this way?

clipboard.png

clipboard.png

        $new_data = [];
        foreach ( $data_regiment as $key => $value) {
            $new_data[date("Y-m-d", strtotime($value["created_at"]))][] = $value;
        }

        $this->json(200, "", $data_regiment);
Php
Jun.25,2021

it's a strange requirement. Y-M-D is the same, but the time is different. What is the requirement?

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e49850-44d1b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e49850-44d1b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?