Summary of Leetcode-Mysql topics and knowledge points (511, gameplay analysis I)

Computer Xiaobai QAQ, because I want to find a few summer internships, I have filled the members and want to focus on the mysql part of leetcode. Write this series of blog posts to communicate with you, and we will continue to update some of the prepared questions in the future. Welcome to communicate with you, and ask the big guys to spray QAQ. Because I have taken many detours as a beginner, I will try my best to write in detail. If you can help future friends, please leave a message to encourage me. Hahahaha.

511. Gameplay Analysis I

There is no new knowledge for this question, and it seems that the two columns of device_id and games_played are useless QAQ

The main idea is to group by group, and then return the minimum value of each group of event_date, which is the date of the first login to the platform.

code show as below:

select player_id,min(event_date) as first_login

from Activity

group by player_id

Guess you like

Origin blog.csdn.net/weixin_43167461/article/details/113186276