I tried viewing the file format in OpenOffice with a different encoding, and I see that if a field in the file doesnt occupy full length, the rest of the empty space has been filled with " "(space).
Now when I do an update or create in the file and use StringBuilder's replace() and then perform the file write operation, the unfilled bytes gets represented as '#'(hash) in the file instead of a space. Do I need to code in such a way so as to preserve the spaces in the file also?(like maybe concatenating unused field length with space). Does Sun view the file separately?
Partner, I added extra spaces to the field value, so the field position is filled with a value + extra spaces. For instance, if a field value can have 64 characters, and the new value has 30 characters, then the value that will be persisted is 30 characters + 34 blank spaces.