This post was last edited by u012376806 on 2013-10-13 19:17:32
The current implementation concerns are a single table structure as follows
Gzid userid Followuserid Remark In_time
Gzid Self-increment
UserID Concern Person ID
Followuserid is the person of concern ID
Remark Notes
In_time Focus Time
How to achieve the attention after the prompt to increase the number of n fans?
And how to prevent users from constantly focusing on and canceling attention to a user
Reply to discussion (solution)
1. Are you prompted to prompt the host after being noticed? New data minus data output difference for a time period
2. Time stamp for a period of time determine whether the operation allows
Be judged before you focus and cancel your attention.
1. Are you prompted to prompt the host after being noticed? New data minus data output difference for a time period
2. Time stamp for a period of time determine whether the operation allows
MySQL query 30 minutes ago Data How to write a query statement AH Unix timestamp
Query the current ID is 1 of the number of fans
Select COUNT (*) as totalb from pd_attentions where followuserid= ' 1 '
Query 30 minutes ago ID is 1 of the number of fans
Select COUNT (*) as totalb from pd_attentions where followuserid= ' 1 ' in_time
Select COUNT (*) as totalb from pd_attentions where followuserid= ' 1 ' and in_time