How to run dynamic query when the pipelines doesn't have data & complete the workflow
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
I am doing some an in-depth processing of data from one database which results in few or no exceptions.
I use a dynamic query to bring some fields from another database and do further processing.
The issue is when I have no data resulting in an exception - the dynamic SQL query fails. What's the best way around this problem?
My dynamic query is simple & complies all the incoming exception IDs into a list using cross-tab& passes it in the query:
Select * from abc
where data = '20221205'
and ID in ('898989', 99999')
I appreciate any help and suggestions.
- Labels:
- Dynamic Processing
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Can you post an example of what you're trying to accomplish?
You have a few options like Detour, dynamically enabling/disabling containers, using a Count tool which always returns one value, etc.
Chris
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
you can throw a count with your first tool. when count != 0 your macro which contains your second query runs otherwise it is skipped.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Thanks for you quick reply.
So my use case looks like this.
In the top flow I have the same two columns but no data as it resulted in no exceptions and I get an error on ConnetionFile & query.
The bottom flow works perfectly whenever I have 1 or multiple results in it.
What is the best way to complete the workflow without error in this case?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Thanks! That's a good idea. Let me try and see if I can make it work.
