2

I have a column in a file that contains html encoded text. I would like to decode this column to text before saving it to the database. What is the best method to do this in data factory?

Neil P
  • 2,920
  • 5
  • 33
  • 64
  • Hi,does my answer helps you? – Jay Gong Oct 25 '19 at 02:34
  • @JayGong Ideally I was looking to see if there was a solution in ADF, but it looks like there isn't, so it may be the way forward – Neil P Oct 25 '19 at 07:25
  • Yes,there is no direct way in ADF,maybe you could try my workaround or you could consider using other services to replace ADF. If you think my answer is beneficial, would you please accept it,thanks a lot! – Jay Gong Oct 25 '19 at 08:40

1 Answers1

0

It seems that decode function in ADF can't decode html directly.

enter image description here

ADF sql server connector supports execution of stored procedure:https://learn.microsoft.com/en-us/azure/data-factory/connector-sql-server#invoke-a-stored-procedure-from-a-sql-sink

You could refer to below threads to decode html with User-Defined Function in sql server:

1.SQL Server: HTML Decode based on the HTML names in a String input

2.Is there any way to do HTML decode in SQL Server?

Then execute function in stored procedure,please refer to this link.

Jay Gong
  • 23,163
  • 2
  • 27
  • 32