Select sheet from excel based on condition
- 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 have a 2 excel workbook one workbook has some record and the second one has multiple sheets. Based on some conditions I have to select the sheet from the second workbook. Example below
2nd workbook has 2 sheets -> Apple and mango
1st workbook has records ->
Fruit |
Apple |
mango |
Condition :
So 1st row which has Apple So I have to open the apple sheet and do a join and if it has mango I have to open sheet name mango and do a join.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi @Sshasnk ,
Great scenario. We would need a batch macro for this.
Can you provide some sample files and expected output so that we can build a workflow.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi @Sshasnk,
I have never build a solution like this but if you will used dynamic input tool you will get list of sheets. Afterwards you can create a filter that will work based on the IF condition. If certain conditions are meet you will load one sheet if they will not be use another one.
For reference how to get list of sheet names:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi @Sshasnk,
Actually I have an alternative scenario. What if you will just use input tool with a sheet name as an output. Do this for two files and then perform union action on them.
You will have 1 data set with 2 sheets inside and you can join both data sets. After they will be joined you can remove the data that you don't need based on the criteria.
Hope this helps.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Great and Interesting approaches @Emil_Kos 😀👍
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi @Sshasnk , I have prepared a mock workflow, can you please have a look and let us know if it works for you?
What I have done is I read all the sheets from another source and filtered it as per requirement.
Thanks.
