cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

SQL GetRows Filter GetSubStringof

The objective of my flow is as follows:

  • Get user input through an MS form.
  • Query on a text value entered in the form, which will be a substring of the value in the database table field. (eg: user enters: "192876", field contains "019287632584  ")

Tried using "substringof" in the "filter Query option", but the Flow throws an error stating:

"message": "An unknown function with name 'substringof' was found

substringof.GIF

What am I doing wrong?
 
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Support
Community Support

Re: SQL GetRows Filter GetSubStringof

Hi @NazIM ,

 

I have made a test on my side, when use the substringof function in the Get row action of SQL Server connector, the flow would run failed with thw same error message as yours.

The substringof function is not supported in the Filter Query in SQL Server currently, as is discussed in the link below:

https://powerusers.microsoft.com/t5/General-Flow-Discussion/ODATA-substringof-not-valid-in-GET-ROWS/...

 

So please take a try with my solution in my first reply to use the "Filter Array" action to achieve your requirement, please let me know if your problem could be solved.

 

Best regards,

Alice       

 

Community Support Team _ Alice Zhang
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

3 REPLIES 3
Highlighted
Community Support
Community Support

Re: SQL GetRows Filter GetSubStringof

Hi @NazIM ,

 

The 'substringof' isn't an exist function in microsoft flow, do you want to use the substring function as link below?

https://docs.microsoft.com/en-us/azure/logic-apps/workflow-definition-language-functions-reference#s...

 

Also if you want to filter items from the sql table, you need to enter the expression in the Filter array field with type as below:

Title eq 'Dynamic content from the form'

 

I suggest that you could take a try with the "Filter array" action since it is easier, please refer to screenshot below:

1.png

 

Best regards,

Alice       

 

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

 

Highlighted
Frequent Visitor

Re: SQL GetRows Filter GetSubStringof

I don't think that is necessary. The filter does work (I have tried the part just before the AND and it works). This (https://veenstra.me.uk/2018/11/12/microsoft-flow-filter-queries-in-sharepoint-get-items/) blog states that substringof is a valid function for the filter query.

 

Dont know what Im missing here.

Highlighted
Community Support
Community Support

Re: SQL GetRows Filter GetSubStringof

Hi @NazIM ,

 

I have made a test on my side, when use the substringof function in the Get row action of SQL Server connector, the flow would run failed with thw same error message as yours.

The substringof function is not supported in the Filter Query in SQL Server currently, as is discussed in the link below:

https://powerusers.microsoft.com/t5/General-Flow-Discussion/ODATA-substringof-not-valid-in-GET-ROWS/...

 

So please take a try with my solution in my first reply to use the "Filter Array" action to achieve your requirement, please let me know if your problem could be solved.

 

Best regards,

Alice       

 

Community Support Team _ Alice Zhang
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

Helpful resources

Announcements
secondImage

August 2020 CYST Winners!

Check out the winners of the recent 'Can You Solve These?' community challenge!

thirdImage

Experience what's new for Power Automate

Join us for an in-depth look at the new Power Automate features and capabilities at the free Microsoft Business Applications Launch Event.

firstImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

thirdimage

Power Automate Community User Group Member Badge

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

Users online (4,772)