# Wm6 wmb2bediconvertToString

**URL:** <https://techcommunity.softwareag.com/t/wm6-wmb2bediconverttostring/107797>\
**Category:** Forum\
**Tags:** EDI\
**Created:** [June 28, 2003, 1:21am UTC](https://techcommunity.softwareag.com/t/wm6-wmb2bediconverttostring/107797 "2003-06-28T01:21:14Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![greg.mitchell.23005](https://avatars.discourse-cdn.com/v4/letter/g/db5fbb/32.png) [@greg.mitchell.23005](https://techcommunity.softwareag.com/u/greg.mitchell.23005)\
**Post date:** [June 28, 2003, 1:21am UTC](https://techcommunity.softwareag.com/t/wm6-wmb2bediconverttostring/107797/1 "2003-06-28T01:21:14Z")

</div>

I’d gotten most of our EDI done up with 4.6, when we decided to migrate to 6.0.1. For the most part, the migration is going smoothly, and in fact, I far prefer 6.0.1’s handling of flatfiles and EDI in general.

The main impetus behind upgrading was the vastly improved generateFA service.

Anyway, under 4.6, wm.b2b.edi:convertToString trimmed spaces, but under 6.0.1 it doesn’t. I’d really really like for it to. I saw the “spacePad” parameter, and thought that if I set it to “none” it might fix everything, but all that does is prevent it from adding spaces - it doesn’t actually remove ones that are already there.

When you’re being charged by the character, I guess every space counts ![](http://www.wmusers.com/wmusers/clipart/happy.gif)

Thanks for whatever help you can give me (I really don’t want to have to put a “trim” transformer on every field map - I know it’s possible, but I’d like to avoid it)

---

<div class="post-metadata">

**Author:** ![Chris\_L](https://avatars.discourse-cdn.com/v4/letter/c/ba9def/32.png) [@Chris\_L](https://techcommunity.softwareag.com/u/Chris_L)\
**Post date:** [June 28, 2003, 2:34am UTC](https://techcommunity.softwareag.com/t/wm6-wmb2bediconverttostring/107797/2 "2003-06-28T02:34:49Z")

</div>

Greg,

Interesting but I never saw that convertToString removed spaces so I used the trim as the last step in my service when mapping records and as the last step in a loop when mapping recordLists.  
Therefore a non-issue for us when we migrated to 6.0.1.

Good Luck!

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 2, 2021, 3:04pm UTC](https://techcommunity.softwareag.com/t/wm6-wmb2bediconverttostring/107797/3 "2021-04-02T15:04:55Z")

</div>


