嗨,这是我的查询..
SELECT u.url,u.url_id,@mailid=wu.email FROM urls_uptime_log u INNER JOIN website_suburls wd ON u.url_id=wd.id
INNER JOIN website_to_sms wu ON wd.websiteId=wu.website_id WHERE u.time_stamp>=DATE_SUB(curdate(),INTERVAL 1 DAY) AND u.status<>200
编辑:我得到的输出表是:(此输出包含站点的 url 状态!=200)
url | url_id |@mailid=wc.email
+-------+------------+----------------
http:/dfg 1616 aaa@gmail.com
+--------+------------+----------------
http:dfff 1621 aaa@gmail.com
+--------+------------+----------------
http:dfff 1619 bbb@ymail.com
我需要查找检查了特定电子邮件的多少个站点?我可以使用以下查询吗?
SELECT COUNT(u.url) FROM urls_uptime_log u INNER JOIN website_suburls wd ON u.url_id=wd.id
INNER JOIN website_to_sms wu ON wd.websiteId=wu.website_id WHERE wu.email=@mailid