arkiboys Did you consider using any if condition checking length of p_CurrentDate? something like the below sample expression/
Note: Capture the Lengths of dataset().p_CurrentDate into a Variable first.
Below expression is just an idea to take decision on the length basis... Please try and do let us know...
dynamic source dataset expression
arkiboys
9,706
Reputation points
Hello,
In ADF copy activity source I have created a dataset to look at .csv file at source.
The format of the source file names are for example:
abc-15 february 2024
abc-14 jan 2024
...
notice the date month can be either long or short.
How can I cater for this month change format in the expression?
At present my expression is like this:
@concat('abc-',formatDateTime(dataset().p_CurrentDate,'dd'), '-',formatDateTime(dataset().p_CurrentDate,'MMM'),'-',formatDateTime(dataset().p_CurrentDate,'yyyy'),'.csv')
Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
Answer accepted by question author
-
QuantumCache 20,676 Reputation points Moderator
2024-02-28T21:43:16.4366667+00:00