cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Olivia_Dudley
Level: Powered On

SubstringOf Query SharePoint Get Items Referencing Expanded Fields

Hi All,

 

I am having a difficult time figuring out how to create a filter based on nested data. If I add a Filter Query to my [SharePoint] Get Items action referencing CN, I have no problems. However, when referencing the nested data, I cannot get the query to return data. What is the proper syntax for getting the substring of a nested value?

 

Sample Filter Query

substringof('T',CN)

Nested Sample Filter Query (Not working)

substringof('C',V_ID/Value)

Sample Return Array Record

{
"@odata.etag": "\"3\"",
"ItemInternalId": "5859",
"ID": 5859,
"CN": "999-T06-99-AS-01",
"MA_ID": {
"@odata.type": "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference",
"Id": 1352,
"Value": "Q24389PT"
},
"MA_ID#Id": 1352,
"C_RF": "Alice Smith",
"C_PM": "Georgia Muldrow",
"V_ID": {
"@odata.type": "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference",
"Id": 42,
"Value": "ABC Company"
},
"V_ID#Id": 42,
"S_ID": {
"@odata.type": "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference",
"Id": 2,
"Value": "Kamasi Washington"
}
}

 

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: SubstringOf Query SharePoint Get Items Referencing Expanded Fields

 

Hi @Olivia_Dudley ,

 

I did a test on my side, it seems that the parameter required by the substringof() function is a field of type string.

Please consider using Filter array or Condition to filter items.

In addition, you could also use Parse JSON to parse the Body of Get items, which can also easily refer to the corresponding field value.

Please refer to this blog to learn more about the use of Parse JSON.

http://johnliu.net/blog/2018/6/a-thesis-on-the-parse-json-action-in-microsoft-flow

 

Best Regards,

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
Community Support Team
Community Support Team

Re: SubstringOf Query SharePoint Get Items Referencing Expanded Fields

 

Hi @Olivia_Dudley ,

 

I did a test on my side, it seems that the parameter required by the substringof() function is a field of type string.

Please consider using Filter array or Condition to filter items.

In addition, you could also use Parse JSON to parse the Body of Get items, which can also easily refer to the corresponding field value.

Please refer to this blog to learn more about the use of Parse JSON.

http://johnliu.net/blog/2018/6/a-thesis-on-the-parse-json-action-in-microsoft-flow

 

Best Regards,

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Olivia_Dudley
Level: Powered On

Re: SubstringOf Query SharePoint Get Items Referencing Expanded Fields

Thanks @v-bacao-msft,

 

I am currently using the Select action to bring any nested fields to the same level. My workaround will have to be utilizing the Filter array action as suggested. Although, I'd like to see if someone has a solution where I could call on the nested string in the Filter Query property of the SharePoint Get Items action. This way, my data set does not need to be filtered twice.

 

Thanks for the link... John Liu is always a great resource!

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

firstImage

Incoming: New and improved badges!

We've given our badges an overhaul and also added some brand new ones!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Kudoed Authors
Users Online
Currently online: 92 members 5,406 guests
Please welcome our newest community members: