gpt4 book ai didi

php - 按天从mysql数据库中获取查询

转载 作者:行者123 更新时间:2023-11-29 05:26:08 25 4
gpt4 key购买 nike

<分区>

我有一个这样的表:

id           view_time               view_cost               view_ip       ect
1 2012-05-03 00:00:00 10 46.196.25.2 ----
2 2012-05-03 00:00:00 30 46.196.25.2 ----
3 2012-05-03 00:00:00 20 46.196.25.2 ----
4 2012-05-04 00:00:00 10 46.196.25.2 ----
5 2012-05-04 00:00:00 80 46.196.25.2 ----
6 2012-05-05 00:00:00 40 46.196.25.2 ----
7 2012-05-05 00:00:00 50 46.196.25.2 ----
8 2012-05-05 00:00:00 10 46.196.25.2 ----
9 2012-05-05 00:00:00 10 46.196.25.2 ----
10 2012-05-05 00:00:00 20 46.196.25.2 ----
11 2012-05-05 00:00:00 10 46.196.25.2 ----

我的结果必须是这样的:

Day          Views          Cost
2012-05-03 3 60
2012-05-04 2 90
2012-05-05 6 140

我正在寻找 Mysql 查询和 php 代码来获得这个结果

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com