如何修复 MS Graph 消息正文搜索? [英] How to fix MS Graph message body search?

查看:35
本文介绍了如何修复 MS Graph 消息正文搜索?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

使用图形资源管理器按主题执行以下消息搜索按预期工作:

Using graph explorer to execute the following message search by subject works as expected:

https://graph.microsoft.com/v1.0/me/messages?$search=%22subject%3Agoogle.com%3A443%2Fsearch%3Fq%3Da%2Btest*%22

但是,此消息按正文搜索失败.这次和之前搜索的唯一区别是主题被替换成了正文:

However, this message search by body fails. The only difference between this and the previous search is that subject is replaced with body:

https://graph.microsoft.com/v1.0/me/messages?$search=%22body%3Agoogle.com%3A443%2Fsearch%3Fq%3Da%2Btest*%22

我在第二次搜索时收到的错误是发生内部服务器错误.操作失败.查询树中的弹出窗口太少".

The error that I receive for the second search is "An internal server error occurred. The operation failed., Too few pops in query tree".

此搜索曾经有效.我该如何解决?

This search used to work. How do I fix it?

推荐答案

这是一个 500 错误 - 你不会让这个工作.我会将此报告为错误.错误似乎与搜索字符串中的第二个冒号有关.

This is a 500 error - you won't make this work. I'll report this as an error. The error appears to be with the second colon in the search string.

$search="body:google.com:443/search?q=a+test*" - 这个 500s

$search="body:google.com443/search?q=a+test*" - 这 200 年

猜想

我怀疑搜索功能现在支持多个字段,因为以下查询按预期工作:

I suspect that the search feature now supports multiple fields as the following query works as expected:

https://graph.microsoft.com/v1.0/me/messages?$search="body:Minerva subject:pilot"

这会破坏您的查询,因为冒号似乎仅用于指定要搜索的字段.

This would break your query as it appears that the colon is only considered for specifying the field to search on.

可能的解决方法

您可以像这样将查询字符串分成多个部分:

You could break your query string into multiple parts like this:

https://graph.microsoft.com/v1.0/me/messages?$search="body:google.com AND body:443/search?q=a+test*"

这还不够,但可能适用于您的场景.

It is not sufficient but may work for your scenario.

这篇关于如何修复 MS Graph 消息正文搜索?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆