大家看看这是什么问题?

Superisboy 2003-12-15 11:27:28
SELECT TOP 100 PERCENT dbo.CallInfoOfProductLineAndBU_new.Period AS 月份,
dbo.BUManageRegion.RegionName AS 大区,
dbo.CodeOfProvince.ProvinceName AS 省份, dbo.CodeOfCity.CityName AS 城市,
dbo.Hospital.HospitalName AS 医院名称,
dbo.CodeOfStandardSectionOffice.name AS 标准科室,
dbo.Doctor.SectionOfficeName AS 挂牌科室, dbo.Doctor.DoctorName AS 医生姓名,
SUM(dbo.CallInfoOfProductLineAndBU_new.Call) AS Call_Num,
dbo.XJ_View_CallCard.StaffName
FROM dbo.XJ_View_CallCard LEFT OUTER JOIN
dbo.Doctor INNER JOIN
dbo.CodeOfProvince INNER JOIN
dbo.CodeOfCity ON
dbo.CodeOfProvince.ProvinceCode = dbo.CodeOfCity.ProvinceCode INNER JOIN
dbo.Hospital INNER JOIN
dbo.BUManageRegion INNER JOIN
dbo.RegionManageDoctor2 ON
dbo.BUManageRegion.RegionRowID = dbo.RegionManageDoctor2.RegionRowID INNER
JOIN
dbo.CodeOfStandardSectionOffice ON
dbo.RegionManageDoctor2.SectionOfficeCode = dbo.CodeOfStandardSectionOffice.SectionOfficeCode
ON dbo.Hospital.HospitalRowID = dbo.RegionManageDoctor2.HospitalRowID ON
dbo.CodeOfCity.CityCode = dbo.Hospital.CityCode ON
dbo.Doctor.DoctorRowID = dbo.RegionManageDoctor2.DoctorRowID ON
dbo.XJ_View_CallCard.HospitalId = dbo.Doctor.HospitalRowID RIGHT OUTER JOIN
dbo.CallInfoOfProductLineAndBU_new ON
dbo.RegionManageDoctor2.DoctorRowID = dbo.CallInfoOfProductLineAndBU_new.DoctorRowID
GROUP BY dbo.CallInfoOfProductLineAndBU_new.Period,
dbo.BUManageRegion.RegionName, dbo.CodeOfProvince.ProvinceName,
dbo.CodeOfCity.CityName, dbo.Hospital.HospitalName,
dbo.CodeOfStandardSectionOffice.name, dbo.Doctor.SectionOfficeName,
dbo.Doctor.DoctorName, dbo.XJ_View_CallCard.StaffName
运行了七分四十九分钟,在企业管理器中显示"超时已过期",怎么优化啊?
...全文
4 点赞 收藏 5
写回复
5 条回复
切换为时间正序
请发表友善的回复…
发表回复
hglhyy 2003-12-21
接分! UP!
回复
wzh1215 2003-12-21
恭喜,接分!!
回复
Superisboy 2003-12-21
已经解决,散分
回复
goldpony 2003-12-15
up
回复
Superisboy 2003-12-15
不好意思,是运行了七分四十九秒
回复
发动态
发帖子
非技术版
创建于2007-09-28

1.1w+

社区成员

MS-SQL Server 非技术版
申请成为版主
社区公告
暂无公告