# FAQ: How do I insert a file name for a field value in FTP imports?

**URL:** <https://connective.celigo.com/t/faq-how-do-i-insert-a-file-name-for-a-field-value-in-ftp-imports/1289>\
**Category:** Integrator.io\
**Tags:** ftp, import, handlebars\
**Created:** [December 9, 2020, 10:47pm UTC](https://connective.celigo.com/t/faq-how-do-i-insert-a-file-name-for-a-field-value-in-ftp-imports/1289 "2020-12-09T22:47:12Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![tomsantiago](https://sea1.discourse-cdn.com/flex001/user_avatar/connective.celigo.com/tomsantiago/32/7158_2.png) [@tomsantiago](https://connective.celigo.com/u/tomsantiago)\
**Post date:** [December 9, 2020, 10:47pm UTC](https://connective.celigo.com/t/faq-how-do-i-insert-a-file-name-for-a-field-value-in-ftp-imports/1289/1 "2020-12-09T22:47:12Z")

</div>

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](https://connective.celigo.com/hc/en-us/sections/360007479691-FTP).

---

<div class="post-metadata">

**Author:** ![troythompson446](https://avatars.discourse-cdn.com/v4/letter/t/e68b1a/32.png) [@troythompson446](https://connective.celigo.com/u/troythompson446)\
**Post date:** [April 15, 2021, 4:33pm UTC](https://connective.celigo.com/t/faq-how-do-i-insert-a-file-name-for-a-field-value-in-ftp-imports/1289/2 "2021-04-15T16:33:02Z")

</div>

Is there an equivalent for FTP exports? This handlebars expression is empty when used as an Export field mapping.

---

<div class="post-metadata">

**Author:** ![stephenbrandt](https://sea1.discourse-cdn.com/flex001/user_avatar/connective.celigo.com/stephenbrandt/32/6891_2.png) [@stephenbrandt](https://connective.celigo.com/u/stephenbrandt)\
**Post date:** [April 15, 2021, 6:22pm UTC](https://connective.celigo.com/t/faq-how-do-i-insert-a-file-name-for-a-field-value-in-ftp-imports/1289/3 "2021-04-15T18:22:17Z")

</div>

@troythompson446, does this variation work with the current Advanced field editor ("AFE 2.0"):

```
 {{{fileMeta.fileName}}}
```

---

<div class="post-metadata">

**Author:** ![troythompson446](https://avatars.discourse-cdn.com/v4/letter/t/e68b1a/32.png) [@troythompson446](https://connective.celigo.com/u/troythompson446)\
**Post date:** [April 15, 2021, 7:05pm UTC](https://connective.celigo.com/t/faq-how-do-i-insert-a-file-name-for-a-field-value-in-ftp-imports/1289/4 "2021-04-15T19:05:46Z")

</div>

No it doesn't. I even tried varying the number of braces.

---

<div class="post-metadata">

**Author:** ![stephenbrandt](https://sea1.discourse-cdn.com/flex001/user_avatar/connective.celigo.com/stephenbrandt/32/6891_2.png) [@stephenbrandt](https://connective.celigo.com/u/stephenbrandt)\
**Post date:** [April 15, 2021, 9:02pm UTC](https://connective.celigo.com/t/faq-how-do-i-insert-a-file-name-for-a-field-value-in-ftp-imports/1289/5 "2021-04-15T21:02:12Z")

</div>

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.

---

<div class="post-metadata">

**Author:** ![brianwaugh](https://sea1.discourse-cdn.com/flex001/user_avatar/connective.celigo.com/brianwaugh/32/4451_2.png) [@brianwaugh](https://connective.celigo.com/u/brianwaugh)\
**Post date:** [August 20, 2021, 5:31pm UTC](https://connective.celigo.com/t/faq-how-do-i-insert-a-file-name-for-a-field-value-in-ftp-imports/1289/6 "2021-08-20T17:31:10Z")

</div>

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.

---

<div class="post-metadata">

**Author:** ![stephenbrandt](https://sea1.discourse-cdn.com/flex001/user_avatar/connective.celigo.com/stephenbrandt/32/6891_2.png) [@stephenbrandt](https://connective.celigo.com/u/stephenbrandt)\
**Post date:** [August 20, 2021, 5:58pm UTC](https://connective.celigo.com/t/faq-how-do-i-insert-a-file-name-for-a-field-value-in-ftp-imports/1289/7 "2021-08-20T17:58:50Z")

</div>

@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.)

---

<div class="post-metadata">

**Author:** ![srikanthsreerama](https://avatars.discourse-cdn.com/v4/letter/s/8491ac/32.png) [@srikanthsreerama](https://connective.celigo.com/u/srikanthsreerama)\
**Post date:** [August 24, 2021, 2:01pm UTC](https://connective.celigo.com/t/faq-how-do-i-insert-a-file-name-for-a-field-value-in-ftp-imports/1289/8 "2021-08-24T14:01:43Z")

</div>

Hi Brian,

We have worked on this requirement and as part of next release, [this capability will be available](https://docs.celigo.com/hc/en-us/articles/4406438887579). 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.
