I have a dataframe with customer-order data that looks like the following:
cust order number order_date total product_id
1 1235846868 2020-01-27 20.0 Product A
1 1235846869 2020-01-27 14.0 Product B
2 1245485221 2020-05-16 11.1 Product B, Product C, Product D
3 1285784226 2020-07-10 24.0 Product D
4 5412151256 2020-03-27 12.0 Product A
4 5412151290 2020-04-13 23.0 Product C, Product B
5 5481581554 2020-02-18 12.0 Product D
As you can see above, there are customers (such as customer "1") who have ordered multiple times on the same day (probably since they forgot to put something into their basked on their first order). I would like to aggregate these multiple orders by customers on the same day but but preserve all other columns I have in the dataset (such as the product_id, order_number, etc.). The output table should look something like this:
cust order number order_date total product_id
1 1235846868, 1235846869 2020-01-27 34.0 Product A, Product B
2 1245485221 2020-05-16 11.1 Product B, Product C, Product D
3 1285784226 2020-07-10 24.0 Product D
4 5412151256 2020-03-27 12.0 Product A
4 5412151290 2020-04-13 23.0 Product C, Product B
5 5481581554 2020-02-18 12.0 Product D
Thank you!