How do I get Activity name using dynamic expression?

Balachandran Kannan 181 Reputation points
2021-03-16T19:23:18.797+00:00

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
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
10,138 questions
{count} vote

1 answer

Sort by: Most helpful
  1. Vaibhav Chaudhari 38,681 Reputation points
    2021-03-17T04:44:07.387+00:00

    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

    1 person found this answer helpful.
    0 comments No comments