Alter row - deleted if/upsert if --> priority1, 2 respectively

arkiboys 9,646 Reputation points
2021-10-06T02:55:08.803+00:00

Hello,
I am trying to allow for the delete to work alongside the upsert but the delete does not seem to work.
As you can see in the screenshots, I have added an extra column (Deleted) in the derived activity so that all rows are set to 0
Then I would like the row which is deleted at source to be set to 1 for the Deleted Column (I have an expression in Alter row for "Deleted" == "1"
Can you please have a look at the screenshots and let me know how I can set the Deleted derived column to 1 for the rows that are detected to be missing in source?
Thank you

138001-image.png
137926-image.png
138002-image.png
137927-image.png
137928-image.png

Azure Synapse Analytics
Azure Synapse Analytics
An Azure analytics service that brings together data integration, enterprise data warehousing, and big data analytics. Previously known as Azure SQL Data Warehouse.
4,422 questions
{count} votes

Accepted answer
  1. ShaikMaheer-MSFT 37,971 Reputation points Microsoft Employee
    2021-10-06T12:43:04.327+00:00

    Hi @arkiboys ,

    Thank you for posting query on Microsoft Q&A Platform.

    Could you please refer answer provided by me in below link which explains how to delete data from Sink when source is not having that IDs.

    https://learn.microsoft.com/en-us/answers/questions/578219/index.html

    On top of above implementation, add another source with your source data and continue your upsert logic by adding alter row transformation on this new branch.

    138211-image.png

    Hope this will help. Please let us know if any further queries.

    ------------------------------

    • Please don't forget to click on 130616-image.png or upvote 130671-image.png 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

0 additional answers

Sort by: Most helpful