The following handlebars expression populates a field with the name of the record's file:
{{{data.fileMeta.fileName}}}
For more information on FTP integrations, see FTP.
The following handlebars expression populates a field with the name of the record's file:
{{{data.fileMeta.fileName}}}
For more information on FTP integrations, see FTP.
Is there an equivalent for FTP exports? This handlebars expression is empty when used as an Export field mapping.
@troythompson446, does this variation work with the current Advanced field editor ("AFE 2.0"):
{{{fileMeta.fileName}}}
No it doesn't. I even tried varying the number of braces.
Thanks for your patience, @troythompson446.
{{{3 curly braces}}} vs. {{2}} shouldn't determine whether the metadata value is retrieved. Three braces are a safeguard for any characters in the file name that would need to be URL-encoded.
[UPDATED 4/20/2021:] Celigo support determined that the fileName metadata is unavailable when the file itself is parsed as records in this case – that is, not treated as "blob" data transferred within the flow. We've initiated a request to add the file information to the flow data in a future release, based on this post.
Hi Stephen, is there an update on this? This seems to be a blocker for us as well.
Here at Bird, we'd like to see this functionality in order to selectively delete FTP files we're processing later in the flow based on whether import was successful or not.
@brianwaugh: Yes. Soon. See your inbox early next week.
(And if I reveal any more than that and steal our product managers' thunder, they too might be wielding axes.)
Hi Brian,
We have worked on this requirement and as part of next release, this capability will be available. Accordingly, a pre-save page hook will take care of the logic to parse the filename and associate it with each data record of file. Also, this filename will be available as part of "export fields" in Import step mapping, where by you can map it to field of your choice in destination FTP file.