# SMT debezium to replace a string with another in topic name

**URL:** <https://forum.confluent.io/t/smt-debezium-to-replace-a-string-with-another-in-topic-name/6959>\
**Category:** Self-Managed Connectors\
**Created:** [5 January 2023 18:11 UTC](https://forum.confluent.io/t/smt-debezium-to-replace-a-string-with-another-in-topic-name/6959 "2023-01-05T18:11:10Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![PitsBee](https://avatars.discourse-cdn.com/v4/letter/p/b487fb/32.png) [@PitsBee](https://forum.confluent.io/u/PitsBee)\
**Post date:** [5 January 2023 18:11 UTC](https://forum.confluent.io/t/smt-debezium-to-replace-a-string-with-another-in-topic-name/6959/1 "2023-01-05T18:11:10Z")

</div>

hi,

I have a Debezium connector that pulls data from SQL server tables.  
It seems the connector creates the topic name like Server.Database.Table.

I want **Server.Database.invitation.Sent.V1** - to be transformed to **invitation.Sent.V2**  
where invitation.Sent.V1 is the table name

Is there a Transform to apply where I can

1. remove Server.Database
2. replace V1 with V2  
in all topics being generated

thanks

---

<div class="post-metadata">

**Author:** ![whatsupbros](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.confluent.io/whatsupbros/32/239_2.png) [@whatsupbros](https://forum.confluent.io/u/whatsupbros)\
**Post date:** [16 January 2023 09:40 UTC](https://forum.confluent.io/t/smt-debezium-to-replace-a-string-with-another-in-topic-name/6959/2 "2023-01-16T09:40:44Z")

</div>

Yes, you should be able to do this with the standard **RegexRouter** SMT: [RegexRouter | Confluent Documentation](https://docs.confluent.io/platform/current/connect/transforms/regexrouter.html#examples)

---

<div class="post-metadata">

**Author:** ![PitsBee](https://avatars.discourse-cdn.com/v4/letter/p/b487fb/32.png) [@PitsBee](https://forum.confluent.io/u/PitsBee)\
**Post date:** [17 January 2023 06:03 UTC](https://forum.confluent.io/t/smt-debezium-to-replace-a-string-with-another-in-topic-name/6959/3 "2023-01-17T06:03:24Z")

</div>

Thanks, i could do it with RegexRouter
