LaxmiSathy
Member
Hello,
Am running this query to get the list of users whose last activity is within a time frame:
SELECT username, date(FROM_UNIXTIME(register_date)), date(FROM_UNIXTIME(last_activity))
FROM `xf_user`
WHERE FROM_UNIXTIME(last_activity) BETWEEN '2017-10-16' AND '2017-10-24'
ORDER BY last_activity DESC
Additionally I need two more column data from the table xf_post that includes:
- timestamp of the last post made by the user in the above list and
-count of posts made by the user within this timeframe
Can you help me with the query. Thanks.
Am running this query to get the list of users whose last activity is within a time frame:
SELECT username, date(FROM_UNIXTIME(register_date)), date(FROM_UNIXTIME(last_activity))
FROM `xf_user`
WHERE FROM_UNIXTIME(last_activity) BETWEEN '2017-10-16' AND '2017-10-24'
ORDER BY last_activity DESC
Additionally I need two more column data from the table xf_post that includes:
- timestamp of the last post made by the user in the above list and
-count of posts made by the user within this timeframe
Can you help me with the query. Thanks.