7.test.mql 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. -- SELECT
  2. -- alertgroup as "分组" , count(*) as "计 数"
  3. -- FROM
  4. -- /m3event/devops/alerts_status group by alertgroup order by "计 数" desc
  5. -- /**
  6. -- output()
  7. -- **/
  8. -- ;
  9. -- SELECT
  10. -- alertgroup as "分组" , count(*) as "计 数"
  11. -- FROM
  12. -- /m3event/devops/alerts_status group by 分组 order by "计 数" desc
  13. -- /**
  14. -- output()
  15. -- **/
  16. -- ;
  17. -- select * from /m3event/devops/alerts_status where severity != 5 limit -1
  18. -- /**
  19. -- output()
  20. -- **/
  21. -- ;
  22. -- update /m3event/devops/alerts_status set tags=tags+'x' where severity = 5
  23. -- ;
  24. -- update /m3event/devops/alerts_status set tags=null where id = 916430775853365296
  25. -- ;
  26. -- update /m3event/devops/alerts_status set tags=tags+'m' where id = 5367294368478167840
  27. -- ;
  28. -- select id,vtime,tags from /m3event/devops/alerts_status where tags = 'x'
  29. -- /**
  30. -- output()
  31. -- **/
  32. -- ;
  33. -- select id,vtime,tags,firstoccurrence,lastoccurrence,internallast,statechange from /m3event/devops/alerts_status where id = 2245957211358017209
  34. -- /**
  35. -- output()
  36. -- **/
  37. -- ;
  38. -- select id,vtime,tags,firstoccurrence,lastoccurrence,internallast,statechange from /m3event/devops/alerts_status where tags = null or tags = 'm' or tags in ('a',"z")
  39. -- /**
  40. -- output()
  41. -- **/
  42. -- ;
  43. -- select id,vtime,tags,firstoccurrence,lastoccurrence,internallast,statechange from /m3event/devops/alerts_status where connect = null
  44. -- /**
  45. -- output()
  46. -- **/
  47. -- ;