Dynamic relative URL for dataset in ADF

Max Muhammad 20 Reputation points
2023-03-27T14:28:29.59+00:00

I am creating a pipeline for Rest API. At 1st task, I am getting a Bearer token (TOKEN CREATE), and next getting a "queryId"(SUBMIT JOB).

User's image

Then I created a REST API dataset, and use my "queryID" from SUBMIT JOB activity so I can paste it in the relative URL section of the dataset. "queryId" changes every time, so it has to be dynamic.

User's image

When pasting the queryID to the relative URL, I am getting an error, as "'activity' is not a recognized function".
User's image

Please advise me

Azure Open Datasets
Azure Open Datasets
An Azure service that provides curated open data for machine learning workflows.
29 questions
Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
11,049 questions
0 comments No comments
{count} votes

Accepted answer
  1. ShaikMaheer-MSFT 38,496 Reputation points Microsoft Employee
    2023-03-28T09:58:38.1966667+00:00

    Hi Max Muhammad,

    Thank you for posting query in Microsoft Q&A Platform.

    Inside dataset you cannot access activity outputs. It's out of scope of dataset. Hence you are seeing that error.
    You can consider having a parameter created inside dataset and then wherever you are using that dataset (In copy activity may be), that time you can pass value to it from other activities if they are connected.

    Please check below screenshots, here web activity (submit job) gets queryId and then in copy activity, I used parameterized dataset and finally passing queryId from first web activity to copy activity.

    User's image

    Hope this helps. Please let me know how it goes and if any further queries.


    Please consider hitting Accept Answer button. Accepted answers help community as well.

    2 people found this answer helpful.

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.