# gatling post body with text

**URL:** <https://community.gatling.io/t/gatling-post-body-with-text/5418>\
**Category:** Gatling (Open-Source)\
**Created:** [January 1, 2020, 11:15pm UTC](https://community.gatling.io/t/gatling-post-body-with-text/5418 "2020-01-01T23:15:56Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![MPhil](https://avatars.discourse-cdn.com/v4/letter/m/2bfe46/32.png) [@MPhil](https://community.gatling.io/u/MPhil)\
**Post date:** [January 1, 2020, 11:15pm UTC](https://community.gatling.io/t/gatling-post-body-with-text/5418/1 "2020-01-01T23:15:56Z")

</div>

I have a request that accepts text in the body a combination of lots of text and the date. When using gatling how do I parameterize the date, so that I can use feeders to keep posting with a new date

---

<div class="post-metadata">

**Author:** ![Arjan\_Luiten](https://avatars.discourse-cdn.com/v4/letter/a/ec9cab/32.png) [@Arjan\_Luiten](https://community.gatling.io/u/Arjan_Luiten)\
**Post date:** [January 23, 2020, 9:01am UTC](https://community.gatling.io/t/gatling-post-body-with-text/5418/2 "2020-01-23T09:01:21Z")

</div>

I am not sure I understand you correctly, but what I do is the following. First I use:

.exec(session =\> {

> val currentDatetime = Calendar._getInstance_()

> val sdf = new SimpleDateFormat(“yyyyMMddHHmmssSSS”)

> sdf.setTimeZone(TimeZone._getTimeZone_(“Europe/Amsterdam”))

> session.set(“variable\_name”, sdf.format(currentDatetime.getTime))

})

After that you can use the date time as variable. You can also add the virtual user id to make it even more unique.
