Search code examples
azureazure-storage

Table Storage - dynamics query in Data Factory


In Storage Table I have dynamicaly generated PartitionKey in YYYY-MM-DD-HH format. And I need querying this in Data Factory Pipeline

I need something like this:

PartitionKey eq DateTime.Now.ToString("yyyyMMddHH")

It is possible? Thanks ...


Solution

  • You could use formatDateTime dynamic date functions in ADF.

    enter image description here

    TEST:

    configuration:

    enter image description here

    output:

    enter image description here


    UPDATE:

    Sorry for my uncompletely answer.I figured it out by using below expression:

    @concat('PartitionKey eq ''', variables('dateValue'),'''')
    

    Screenshot:

    enter image description here

    Entire structure:

    enter image description here

    I got some clues from this link,also provide for you:Azure Data Factory Expression Query for Copy activity.