phpmyadmin错误解释

jk9hmnmh  于 2021-06-25  发布在  Mysql
关注(0)|答案(1)|浏览(245)

在phpmyadmin的v4.5.5.1中,我运行以下mysql代码;

SELECT Date, DOW, Week, Year, logdate, Month, monum, netID, Logins, 
       creds, newb, netCnt, TOD, netCnt, activity
  FROM (SELECT logdate
              ,activity
              ,DATE( logdate )                      AS Date
              ,DAYOFWEEK( logdate )         AS DOW
              ,WEEK( logdate,0 )              AS Week
              ,YEAR( logdate )              AS Year
              ,DATE_FORMAT( logdate, '%M' )         AS Month
              ,DATE_FORMAT( logdate, '%m' )     AS monum
              ,CONVERT( netID,UNSIGNED INTEGER )    AS netID
              ,COUNT( callsign )                    AS Logins
              ,COUNT( IF(creds <> '',1,NULL) )  AS creds
              ,COUNT( IF(comments LIKE '%first log in%',1,NULL) ) AS newb
              ,count( DISTINCT netID )      AS netCnt
              ,SUM(  DISTINCT netID)            AS allCnt
              ,SEC_TO_TIME( SUM(timeonduty) )       AS TOD
         FROM NetLog
        WHERE netID <> 0 
          AND activity NOT LIKE '%TEST%'
          AND netcall LIKE '%W0KCN%'
          AND substr(logdate,1,4) = 2017
    GROUP BY Month, netID WITH ROLLUP ) AS t 
    ORDER BY t.logdate , logins

它运行得很好,我需要的东西都还回来了,但是。。。我在第3行的“from(select logdate)”处发现三个错误

我在第23行也得到了5个错误'组每月,netid与汇总)作为t'。。。

这些是什么意思?我应该解决它们吗?当然,我该如何解决它们?

7lrncoxx

7lrncoxx1#

您声明:
在v4.5.5.1中
phpmyadmin当前版本是4.7.7,您可以在这里获得它。
我已经在我的4.7.3版本中运行了您的查询,运行时不会显示这些错误。
问题是你的4.5.5版本是在2015年发布的,所以很旧。。。bug得到修复,代码得到改进,phpmyadmin在处理高级sql语法检查方面总是落后一点。
我赞同塔德曼的评论
phpmyadmin不像mysql workbench那样健壮,所以如果您可以选择使用workbench

相关问题