Hello anonymous user ,
Thanks for the ask and using Microsoft Q&A platform .
This is what I will suggest ,
- Use a lookup ( lets name it Get distinct year ) , to get all the distinct years , Since you have SQL as source . A simple query like
"Select ditinct year from some table " should work .
- Use a foreach and use the output of the lookup eg
@activity('Get distinct year ').output.value
- Inside the Lookup , add a copy activity in the source option use the query and create a dynamic expression .
@firstname.lastname@example.org ('select * from [dbo].[YourTableName] where year=' , item().year ) .
Please do let me know how it goes .
- Please don't forget to click on or upvote button whenever the information provided helps you. Original posters help the community find answers faster by identifying the correct answer. Here is how
- Want a reminder to come back and check responses? Here is how to subscribe to a notification
- If you are interested in joining the VM program and help shape the future of Q&A: Here is how you can be part of Q&A Volunteer Moderators