Sharepoint:带有条件的多个细化过滤器(对 Angular4 使用 rest API)
Sharepoint: Multiple refinement filters with and condition (Using rest API for Angular4)
我正在使用 SharePoint rest api 检索数据:
myURL/_api/search/query?rowlimit=500&trimduplicates=false+ .... +
refinementfilters=%27CountryCDH:("USA")%27,%27(ColorChoiceCDH:("Red"),ColorChoiceCDH:("Blue"))%27
这是我的要求:
我确实有三列可以对数据进行混合搜索。
国家(可以是美国,英国,..)
颜色(可以是red/blue/green)
- 类型(S、M、L、XL)
如何从中创建优化过滤器查询?
目前遇到构建查询的问题。
-1, Microsoft.SharePoint.Client.InvalidClientQueryException
The expression "'CountryCDH:("USA")','(ColorChoiceCDH:("Red"),ColorChoiceCDH:("Blue"))'" is not valid.
提前致谢。帮我建立查询
作为 AND 和 OR 的一般模式:
&refinementfilters='or(fileExtension:equals("docx"),fileExtension:equals("pptx"))'
假设您正在使用 refinable 属性,它们可能类似于:
&refinementfilters='and(CountryCDH:equals("USA"),ColorChoiceCDH:equals("Red"),ColorChoiceCDH:equals("Blue"))'
我正在使用 SharePoint rest api 检索数据:
myURL/_api/search/query?rowlimit=500&trimduplicates=false+ .... +
refinementfilters=%27CountryCDH:("USA")%27,%27(ColorChoiceCDH:("Red"),ColorChoiceCDH:("Blue"))%27
这是我的要求: 我确实有三列可以对数据进行混合搜索。
国家(可以是美国,英国,..)
颜色(可以是red/blue/green)
- 类型(S、M、L、XL)
如何从中创建优化过滤器查询?
目前遇到构建查询的问题。
-1, Microsoft.SharePoint.Client.InvalidClientQueryException
The expression "'CountryCDH:("USA")','(ColorChoiceCDH:("Red"),ColorChoiceCDH:("Blue"))'" is not valid.
提前致谢。帮我建立查询
作为 AND 和 OR 的一般模式:
&refinementfilters='or(fileExtension:equals("docx"),fileExtension:equals("pptx"))'
假设您正在使用 refinable 属性,它们可能类似于:
&refinementfilters='and(CountryCDH:equals("USA"),ColorChoiceCDH:equals("Red"),ColorChoiceCDH:equals("Blue"))'