-- SELECT * FROM t_videoTalkRecord;
-- SELECT * FROM t_videoTalkRecord WHERE id IN (SELECT max(id)
-- FROM t_videoTalkRecord GROUP BY userId HAVING count(*) >= 1) AND
-- currentLoginUserId = '9999' AND recordType = 3 ORDER BY currentRecordSaveTimeStamp DESC;
-- SELECT * FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- t_videoTalkRecord GROUP BY userId HAVING count(*) >= 1) AND currentLoginUserId = '9999'
-- AND recordType = 3 ORDER BY currentRecordSaveTimeStamp DESC;
-- SELECT * FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- t_videoTalkRecord GROUP BY userId HAVING count(*) >= 1) AND currentLoginUserId = '9999'
-- AND recordType = 3;
-- SELECT * FROM t_videoTalkRecord WHERE userId IN(SELECT * FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- t_videoTalkRecord GROUP BY userId HAVING count(*) >= 1) AND currentLoginUserId = '9999'
-- AND recordType = 3);
-- SELECT max(id) FROM
-- t_videoTalkRecord WHERE currentLoginUserId = '9999' GROUP BY userId HAVING count(*) >= 1
--
-- SELECT * FROM
-- t_videoTalkRecord WHERE currentLoginUserId = '9999' AND recordType = 2 GROUP BY userId HAVING count(*) >= 1
-- SELECT max(id) FROM
-- t_videoTalkRecord WHERE currentLoginUserId = '9999' AND recordType = 2 GROUP BY userId HAVING count(*) >= 1
-- //查找去过重的未接记录
-- SELECT * FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- t_videoTalkRecord WHERE currentLoginUserId = '9999' AND recordType = 2 GROUP BY userId HAVING count(*) >= 1) AND
-- currentLoginUserId = '9999' AND recordType = 2 ORDER BY currentRecordSaveTimeStamp DESC;
-- //好友关系去除重复
-- SELECT max(id) FROM
-- t_videoTalkRecord WHERE currentLoginUserId = '9999' AND recordType = 3 GROUP BY userId HAVING count(*) >= 1
--
-- //查找好友去除重复 - 好友userid
-- SELECT userId FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- t_videoTalkRecord WHERE currentLoginUserId = '9999' AND recordType = 3 GROUP BY userId HAVING count(*) >= 1) AND
-- currentLoginUserId = '9999' AND recordType = 3;
-- //查找未接记录已经去重未接重复记录 并且 去除 非好友未接记录
-- SELECT * FROM (SELECT * FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- t_videoTalkRecord WHERE currentLoginUserId = '9999' AND recordType = 2 GROUP BY userId HAVING count(*) >= 1) AND
-- currentLoginUserId = '9999' AND recordType = 2) WHERE userId IN(SELECT userId FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- t_videoTalkRecord WHERE currentLoginUserId = '9999' AND recordType = 3 GROUP BY userId HAVING count(*) >= 1) AND
-- currentLoginUserId = '9999' AND recordType = 3);
-- //查找好友已经去重好友重复记录
SELECT * FROM (SELECT * FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
t_videoTalkRecord WHERE currentLoginUserId = '9999' AND recordType = 3 GROUP BY userId HAVING count(*) >= 1) AND
currentLoginUserId = '9999' AND recordType = 3) WHERE userId IN(SELECT userId FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
t_videoTalkRecord WHERE currentLoginUserId = '9999' AND recordType = 3 GROUP BY userId HAVING count(*) >= 1) AND
currentLoginUserId = '9999' AND recordType = 3) ORDER BY currentRecordSaveTimeStamp DESC;
-- SELECT * FROM t_videoTalkRecord WHERE id IN () AND
-- currentLoginUserId = '9999' AND recordType = 2 ORDER BY currentRecordSaveTimeStamp DESC;
-- SELECT * FROM t_videoTalkRecord WHERE currentLoginUserId = '9999' AND recordType = 2;
-- SELECT userId FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- t_videoTalkRecord GROUP BY userId HAVING count(*) >= 1) AND currentLoginUserId = '9999'
-- AND recordType = 2;
-- SELECT max(id) FROM
-- t_videoTalkRecord GROUP BY userId HAVING count(*) >= 1
-- SELECT userId FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- t_videoTalkRecord GROUP BY userId HAVING count(*) >= 1) AND currentLoginUserId = '9999'
-- AND recordType = 3
-- SELECT * FROM t_videoTalkRecord WHERE userId IN (SELECT userId FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- t_videoTalkRecord GROUP BY userId HAVING count(*) >= 1) AND currentLoginUserId = '9999'
-- AND recordType = 3);
-- SELECT * FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- (SELECT * FROM t_videoTalkRecord WHERE userId IN (SELECT userId FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- t_videoTalkRecord GROUP BY userId HAVING count(*) >= 1) AND currentLoginUserId = '9999'
-- AND recordType = 2)) GROUP BY userId HAVING count(*) >= 1) AND currentLoginUserId = '9999'
-- AND recordType = 3 ORDER BY currentRecordSaveTimeStamp DESC;
-- SELECT * FROM t_videoTalkRecord WHERE userId IN(SELECT * FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- t_videoTalkRecord GROUP BY userId HAVING count(*) >= 1) AND currentLoginUserId = '9999'
-- AND recordType = 3 ORDER BY currentRecordSaveTimeStamp DESC);
-- SELECT * FROM t_videoTalkRecord WHERE userId IN (SELECT * FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- t_videoTalkRecord GROUP BY userId HAVING count(*) >= 1));
-- SELECT * FROM t_videoTalkRecord WHERE id IN (SELECT max(id) FROM
-- t_videoTalkRecord GROUP BY userId HAVING count(*) >= 1) AND currentLoginUserId = '9999'
-- AND recordType = 3
服务器托管,北京服务器托管,服务器租用 http://www.fwqtg.net
机房租用,北京机房租用,IDC机房托管, http://www.fwqtg.net
目录 🌟一、单例模式 🌈1、饿汉模式 🌈2、懒汉模式(重点!) 🌟二、工厂模式 🌟三、阻塞式队列 🌈1、阻塞队列是什么? 🌈2、阻塞队列:生产者-消费者模型 🌈3、消息队列的作用 🌈4、演示JDK中提供的阻塞队列 🌈5、自己实…