Sql-docs: What is the Synapse equivalent of "FOR XML PATH"?

Created on 27 May 2020  ·  9Comments  ·  Source: MicrosoftDocs/sql-docs

This thread says that FOR XML PATH() is unsupported. However, I am not interested in loading XML data, rather using the FOR XML PATH() to create a list of executable sql statements.

On this page, you should link to the the STRING AGG page and mention this SO answer!


Document Details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

Pri1 assigned-to-author doc-bug sqprod xmtech

All 9 comments

@swanderz -- Anders, thank you for your thorough feedback.

@rothja -- Jason, please look into this issue.

this is one small ask as part of this issue in the Azure docs
https://github.com/mikaelene/dbt-sqlserver/issues/19

@swanderz Thanks for the question. I'm going to ask @julieMSFT to take a look, as she works on the content for Azure Synapse Analytics. #reassign:julieMSFT

Thank you!

julieMSFT. is not a valid GitHub ID, or is not a collaborator on this repo.

@swanderz Hi Anders. Thank you for contacting Microsoft. I am looking into your comments.

@julieMSFT I linked the wrong issue above. Here (https://github.com/MicrosoftDocs/azure-docs/issues/55713), I hint that STRINGAGG() is the answer.

my high level SQL doc feedback is that while I appreciate that you've consolidated the T-SQL function ref across products to avoid duplication, I don't think this works for the persona that is trying to translate between TSQL implementations. I also opened this issue on the same topic. https://github.com/MicrosoftDocs/azure-docs/issues/55713 @WilliamAntonRohm

I think using the analogy of offering an analogy of a language translation dictionary. Imagine I'm a Spanish speaker who is trying to learn how to say _biblioteca_ in English. So I google "biblioteca English" and am brought to a page that has this at the top.

_biblioteca_
Spanish: ✔️ Italian: ✔️ English: ❌

At this point, I have nowhere to go next. And the presence of the word, "English", is going to bring me to that entry even though biblioteca isn't a word in English.

This is the experience of someone trying to figure out how to develop in Synapse that is coming from SQL server.

FOR XML PATH (SQL SERVER)
image

@swanderz Thank you for providing more clarifying information. I do understand the issue. I have crated a work item to track this suggestion. I will close this issue but will let you know when we decide how to address the concern you raise here. The @notification mechanism continues to work even after an item is closed, in case further communication is needed. We hope to hear from you again.

Was this page helpful?
0 / 5 - 0 ratings