serverless sql pool upsert

arkiboys 9,641 Reputation points
2021-09-29T09:57:34.693+00:00

Hi,
I am using serverless sql pool in synapse workspace.
step1-
I am storing the data into .parquet files.
To read the parquet files I use the openrowset sql query in a view, i.e. view1.
Question:
step 2-
Is it possible to create a view, i.e. view2 which does upsert in view1?
If not, do I need to create dataflow for this operation? i.e. source being the parquet file and destination to be upsert on the parquet?

Thank you

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,395 questions
0 comments No comments
{count} vote

Accepted answer
  1. HimanshuSinha-msft 19,381 Reputation points Microsoft Employee
    2021-09-30T19:54:47.073+00:00

    Hello @arkiboys ,
    Thanks for the ask and using Microsoft Q&A platform .
    View are just a metadata on the underlying records and so it is always a SELECT statement . In sort you cannot update records using views , if your intend is to perform a UPSERT , you will have to make the changes on the underlying datasource .

    Please do let me know how it goes .
    Thanks
    Himanshu

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

    • 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 comments No comments

1 additional answer

Sort by: Most helpful
  1. Dennis BC 1 Reputation point
    2021-10-01T06:34:28.697+00:00

    Is it something like this:

    Via a synapse integration pipeline, you have made a directory with parquet files from a full copy of a table, and now you would like the changes in the table, to be reflected in the parquet files as well (without full loading the table again and again)?

    Have you considered doing a delta load to a separate directory, and then union and deduplicate the datasets in your view?

    0 comments No comments