cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Super User
Super User

DB2 CONNECTOR: Filter and Select Query Examples?

Hello,

I have a Flow that writes data to DB2 tables. After a write is successful, I want to send out a report that shows ONLY the new records written to the database. 

 

I have a variable called varObjectIDs that is set earlier in the Flow. Its a string variable that looks like: "1,2,3" etc. and holds the ID's of the new tables.

 

Question is: 

  • How do I use varObjectIDs to select only the new records in a DB2 Get Rows action? 

I think the answer lies with the "Filter Query" or "Select Query" paramenters but I don't understand them enough to use them. 

image.png

 

I tried putting OBJECTID eq varObjectIDs in the Filter Query, but Flow didn't accept that.

Any other ideas?

Thank you!

2 REPLIES 2
Super User
Super User

Re: DB2 CONNECTOR: Filter and Select Query Examples?

Hi @ericonline 

 

I am no DB2 expert but if your variable contains the ids in string format

OBJECTID eq varObjectIDs will not work

 

you might have to loop through each varObjectIDs and test the query and check if record exists

 

one option would be to hardcode the id and check first if it works

example : OBJECTID eq '1' 

or OBJECTID eq 1

 

based on response you can set your query accordingly

 

Regards,

Reza Dorrani

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

 

Community Support Team
Community Support Team

Re: DB2 CONNECTOR: Filter and Select Query Examples?

Hi @ericonline,

 

If you use Filter array, you need to put the current item into the left or right blank, and the other side you need to put the value you want find.Annotation 2019-08-13 112236.png

Best Regards,

Community Support Team _ Lin Tu

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

Helpful resources

Announcements
firstImage

Microsoft Business Applications Virtual Launch Event

Watch the event on demand for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 Release Wave 2 Plan

Power Platform 2019 Release Wave 2 Plan

Features releasing from October 2019 through March 2020.

thirdimage

Flow Community User Group Member Badge

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

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 Flow Community Video Gallery!

Users Online
Currently online: 212 members 3,267 guests
Please welcome our newest community members: