select * from (
SELECT agency_id,username, count( authorid ) AS num,sum(replynum ) as replynum
FROM `agencypartreply`
WHERE replynum >4
AND countdate > UNIX_TIMESTAMP( '2012-09-01' )
AND countdate < UNIX_TIMESTAMP( '2012-11-01' )
GROUP BY username
) as a
FULL JOIN
agencyuser as u on u.id = a.agency_id where a.num > 21
SELECT agency_id,username, count( authorid ) AS num,sum(replynum ) as replynum
FROM `agencypartreply`
WHERE replynum >4
AND countdate > UNIX_TIMESTAMP( '2012-09-01' )
AND countdate < UNIX_TIMESTAMP( '2012-11-01' )
GROUP BY username
) as a
FULL JOIN
agencyuser as u on u.id = a.agency_id where a.num > 21
解决方案 »
- Mysql服务启动1067错误
- 时时检查文件下的文件并导入数据库
- MySQL Cluster 问题请教
- java操作mysql数据库存储过程获取存储过程的参数列表??
- 咳咳...ACMAIN_CHM在吗?
- 有知道哪有MySQL的汉化/简体中文版下载吗?
- 請教大家, mysql 數據庫的備份和備份恢復怎樣進行,是怎麼操作的???
- 我在客户端用mysql -u root就可以轻易进入数据库,这是怎么回事,我用mysql_setpermission设置root的密码,在客户端依然如此,我该怎么才
- 如何使用,MYSQL中的MySqlManager.exe管理工具? 还望大家拨刀相助!!
- load data infile命令导入txt 转义符号\给过滤了
- 我把linux下的mysql文件夹拷贝了下来,想在windows下的mysql上恢复数据
- mysql多表删除 快点 再快点....
union all
select * from A.right join B on A.id=B.id