I have 2 seperate arrays called $all_requests_messages
and $all_messages.
These 2 array results are taken from same table but on applying different queries .Now i need to merge 2 arrays and list the result based on the primary key of the table. Is it possible ?
$all_requests_messages = $this->users_model->getAllRequests_Messages($arr['user_id']);
$all_messages = $this->users_model->getTypeMessage($arr['user_id'],0);
$all_requests_messages = array_merge($all_messages,$all_requests_messages);
need to sort the $all_requests_messages based on primary key value of the table .