question

balaa-uk avatar image
1 Vote"
balaa-uk asked SaurabhSharma-msft commented

How do I get Activity name using dynamic expression?

I have a copy activity which is set to skip incompatible rows and logging enabled. It is logging skipped rows to a folder ../copyactivity-logs/{copy-activity-name}/{runid}/some-file.txt

I want to store these logs into sql server database with a specific column showing at which activity it failed. How do I get the activity name using dynamic expression?

azure-data-factory
· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

@balaa-uk did Vaibhav's answer solve your issue? If so, please mark as answer, otherwise let us know how to better assist.

0 Votes 0 ·

@balaa-uk Following up as we have not heard back from you.

0 Votes 0 ·

1 Answer

VaibhavChaudhari avatar image
1 Vote"
VaibhavChaudhari answered

One option to try is enable audit logging to log analytics which should log all the pipeline run details to LA workspace. Later you can run KQL queries just like SQL queries and see if you get the desired results there

Another option is to setup custom logging to SQL within pipeline where you insert the logging details to SQL using SPs..

For reference - https://www.mssqltips.com/sqlservertip/6712/azure-data-factory-pipeline-logging-error-details/


Please don't forget to Accept Answer and Up-vote if the response helped -- Vaibhav

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.