refactor: 优化查询访客地域分布信息接口 SQL
This commit is contained in:
parent
e6c6e1cb0e
commit
4df887d826
@ -38,10 +38,10 @@
|
||||
|
||||
<select id="selectListDashboardGeoDistribution" resultType="java.util.Map">
|
||||
SELECT
|
||||
`address` AS name,
|
||||
SUBSTRING_INDEX(`address`, ' ', 1) AS name,
|
||||
COUNT(DISTINCT `ip`) AS value
|
||||
FROM `sys_log`
|
||||
GROUP BY `address`
|
||||
GROUP BY `name`
|
||||
ORDER BY COUNT(DISTINCT `ip`) DESC
|
||||
LIMIT 10
|
||||
</select>
|
||||
|
Loading…
Reference in New Issue
Block a user