mattcasters opened a new pull request, #8690: URL: https://github.com/apache/hop/pull/8690
Text File Output always wrote string values padded with spaces out to the field length, even when Right pad fields was not selected. Fast data dump avoided those spaces only by skipping formatting as well. Lengths picked up from a database, including through metadata injection, therefore showed up as trailing spaces in the file. A new Content tab option, Do not right-pad fields, skips that padding. Values longer than the field length are still shortened. The option is absent from transforms saved before this change, so those keep padding. A newly created transform checks it. Metadata injection can set the same choice with DO_NOT_RIGHT_PAD_FIELDS. Right pad fields is unchanged and still does not turn this padding off by itself. Uncheck Do not right-pad fields when a fixed-width file is required. Ran `tools/with-isolated-display.sh ./mvnw -pl plugins/transforms/textfile -am test -Dtest=TextFileOutputTest,TextFileOutputMetaTest -Dsurefire.failIfNoSpecifiedTests=false` (17 tests, all passed) and `./mvnw -pl plugins/transforms/textfile spotless:apply`. fixes #4303 ------------------------ Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily: - [ ] Run `mvn clean install apache-rat:check` to make sure basic checks pass. A more thorough check will be performed on your pull request automatically. - [x] If you have a group of commits related to the same change, please squash your commits into one and force push your branch using `git rebase -i`. - [x] Mention the appropriate issue in your description (for example: `addresses #123`), if applicable. To make clear that you license your contribution under the [Apache License Version 2.0, January 2004](http://www.apache.org/licenses/LICENSE-2.0) you have to acknowledge this by using the following check-box. - [x] I hereby declare this contribution to be licensed under the [Apache License Version 2.0, January 2004](http://www.apache.org/licenses/LICENSE-2.0) - [ ] In any other case, please file an [Apache Individual Contributor License Agreement](https://www.apache.org/licenses/icla.pdf). -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
