# Impossible to rename a field

**URL:** https://discuss.elastic.co/t/impossible-to-rename-a-field/301956
**Category:** Logstash
**Created:** [April 8, 2022, 11:06am UTC](https://discuss.elastic.co/t/impossible-to-rename-a-field/301956 "2022-04-08T11:06:48Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![mehdielfi](https://avatars.discourse-cdn.com/v4/letter/m/5daacb/32.png) [@mehdielfi](https://discuss.elastic.co/u/mehdielfi)
#### Post date: [April 8, 2022, 11:06am UTC](https://discuss.elastic.co/t/impossible-to-rename-a-field/301956/1 "2022-04-08T11:06:48Z")

</div>

Hi i struggle to find the solution  
i try to rename a JSON field from X-Global-Transaction-Id to X-Global-Transaction-ID

Here is the filter logstash

```auto
filter {
        mutate {
           rename => {"[response_http_headers][X-Global-Transaction-Id]" => "[response_http_headers][X-Global-Transaction-ID]"}
        }
}

```

Here is an example of the Json StdOutput

```auto
{
	"_index": "xxxxxxxx",
	"_type": "_doc",
	"_id": "HeqUCIABagtUMClu6Ieg",
	"_version": 1,
	"_score": 1,
	"_source": {		
		"response_http_headers": {
			"X-Global-Transaction-Id": "XXXXXXXX",
			"X-RateLimit-Limit": "name=default-rate-limit,200000;name=hard-limits-per-sec,15;",
			"X-Request-ID": "5bba9a58-b724-11ec-ab8b-ac1e3f1f0000",
			"Server": "IBM App Connect Enterprise",
			"Content-Type": "application/json;charset=utf-8",
			"X-Correlation-ID": "5bba9a58-b724-11ec-ab8b-ac1e3f1f0000",
			"X-RateLimit-Remaining": "name=default-rate-limit,125848;name=hard-limits-per-sec,14;",
			"Date": "Fri, 08 Apr 2022 10:12:14 GMT"
		}
    },
    "fields": {
	......
	}
}

```

Can you help me please.  
Thank you.

---

<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: [May 6, 2022, 11:07am UTC](https://discuss.elastic.co/t/impossible-to-rename-a-field/301956/2 "2022-05-06T11:07:36Z")

</div>

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