62,046
社区成员
发帖
与我相关
我的任务
分享
USE myDB
if object_id('SHManagers','U') is not null
drop table SHManagers
GO
create table SHManagers(
ID int identity(1,1) not null,
TexNames nchar(10),
TexJSUser nchar(10)
)
GO
测试用数据
要实现的功能
select TexNames,count(*) as heji from SHManagers where TexJSUser='aaa' group by TexNames order by heji DESC
结果