zoukankan      html  css  js  c++  java
  • 错误: Aggregate query has too many rows > 不需要用子查询

    Aggregate query has too many rows for direct assignment, use FOR loop

    错误的代码:

     if (query == '' || query == null){
       query = 'SELECT id, name, ownerid, Planned_Visits__c,  Actual_Visits__c, Visits_last_Year__c, ' +
         '  (SELECT AccountId, id, Type, ActivityDate, Visit_Report__c ' +
         '   FROM events WHERE AccountId != null and Type != null and ActivityDate != null and Type = \'Sales Visit\' and Visit_Report__c = TRUE AND  ) ' +
         'FROM Account where owner.IsActive = true ' +
         //'     AND id IN(\'001P000000ZKblDIAT\', \'001P000000ZKboRIAT\', \'001P000000ZKd55IAD\', \'001P000000ZKd5KIAT\', \'001P000000ZKd5UIAT\')' +
         '';
      }

  • 相关阅读:
    Ztree-
    富文本编辑器Ueditor
    通知 弹框
    ResultEntity
    echart
    定时器,定时发邮件JavaMail
    重定向传值
    图片验证码
    异步json发送put或者delete
    异步时间格式转换插件
  • 原文地址:https://www.cnblogs.com/yqskj/p/2750127.html
Copyright © 2011-2022 走看看