监理公司管理系统 | 工程企业管理系统 | OA系统 | ERP系统 | 造价咨询管理系统 | 工程设计管理系统 | 甲方项目管理系统 | 签约案例 | 客户案例 | 在线试用
X 关闭
培训学校管理系统

当前位置:工程项目OA系统 > 学校OA管理系统 > 相关系统 > 培训学校管理系统

更新未到访视图FZJView

申请免费试用、咨询电话:400-8352-114

    SELECT   dbo.Clue.uClu_ID, dbo.Clue.dClu_CreateTime, dbo.Clue.cClu_Num, dbo.Clue.cClu_CName, dbo.Clue.iClu_Age,
                dbo.Clue.cClu_Phone, dbo.Grade.cGra_Name AS 年级, dbo.ExtensionWorkers.cExtW_Num AS 推广人员,
                dbo.Clue.cClu_State, dbo.Clue.cClu_KCGW, dbo.Channel.cCha_Name AS 渠道,
                TMKRecord.cTMKR_Intention AS 意向状态, dbo.Clue.dClu_CreateTime AS 创建时 间, dbo.Clue.cClu_HFRY
FROM      dbo.Clue LEFT OUTER JOIN
                dbo.Channel ON dbo.Clue.uClu_ChaId = dbo.Channel.uCha_ID LEFT OUTER JOIN
                    (SELECT   uCha_CluId
                     FROM      dbo.Charge AS Charge_1
                     GROUP BY uCha_CluId) AS Charge ON dbo.Clue.uClu_ID = Charge.uCha_CluId LEFT OUTER JOIN
                dbo.Grade ON dbo.Grade.uGra_ID = dbo.Clue.uClu_GraId LEFT OUTER JOIN
                dbo.ExtensionWorkers ON dbo.ExtensionWorkers.uExtW_ID = dbo.Clue.uClu_ExtWId LEFT OUTER JOIN
                    (SELECT   TMKRecord_1.uTMKR_CluId, MAX(TMKRecord_1.cTMKR_Intention) AS cTMKR_Intention,
                                     MAX(TMKRecord_1.dTMKR_ContactTime) AS dTMKR_ContactTime, COUNT(*) AS TMKCount,
                                     MAX(dbo.[User].cUser_Name) AS cUser_Name
                     FROM      dbo.TMKRecord AS TMKRecord_1 LEFT OUTER JOIN
                                     dbo.[User] ON TMKRecord_1.uTMKR_TMKId = dbo. [User].uUser_ID
                     GROUP BY TMKRecord_1.uTMKR_CluId) AS TMKRecord ON TMKRecord.uTMKR_CluId = dbo.Clue.uClu_ID
WHERE   (dbo.Clue.cClu_State = '未到访') AND (Charge.uCha_CluId IS NULL)   FZJView
发布:2007-03-30 10:26    编辑:泛普软件 · xiaona    [打印此页]    [关闭]