# Is there a way to add label to both sampled and non sampled transaction?

**URL:** https://discuss.elastic.co/t/is-there-a-way-to-add-label-to-both-sampled-and-non-sampled-transaction/273030
**Category:** APM
**Tags:** java
**Created:** [May 14, 2021, 2:22pm UTC](https://discuss.elastic.co/t/is-there-a-way-to-add-label-to-both-sampled-and-non-sampled-transaction/273030 "2021-05-14T14:22:02Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Nandu\_Bhai](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nandu_bhai/32/79690_2.png) [@Nandu\_Bhai](https://discuss.elastic.co/u/Nandu_Bhai)
#### Post date: [May 14, 2021, 2:22pm UTC](https://discuss.elastic.co/t/is-there-a-way-to-add-label-to-both-sampled-and-non-sampled-transaction/273030/1 "2021-05-14T14:22:02Z")

</div>

I just want a key with 5 types of values associated with each request transaction. I was using the labels to achieve the purpose. But after enabling the sampling, the labels are coming with only sampled requests. Is there any way around this?

---

<div class="post-metadata">

### Author: ![Nandu\_Bhai](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nandu_bhai/32/79690_2.png) [@Nandu\_Bhai](https://discuss.elastic.co/u/Nandu_Bhai)
#### Post date: [May 17, 2021, 3:47pm UTC](https://discuss.elastic.co/t/is-there-a-way-to-add-label-to-both-sampled-and-non-sampled-transaction/273030/2 "2021-05-17T15:47:46Z")

</div>

bump

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [June 7, 2021, 11:48am UTC](https://discuss.elastic.co/t/is-there-a-way-to-add-label-to-both-sampled-and-non-sampled-transaction/273030/3 "2021-06-07T11:48:36Z")

</div>

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.
