3 ms·
> Anyone who works with texts today as a programmer who doesn't understand the basics of character encoding is likely in trouble And they can create a lot of t
by magicalhippo 6y ago
> Anyone who works with texts today as a programmer who doesn't understand the basics of character encoding is likely in trouble
And they can create a lot of trouble!
We have to deal with a system which generates what they call XML files using simple string concats, without regard for encoding. So while the header says encoding="utf-8", the data is a mix of different encodings depending on which database the data comes from, none of them being UTF-8.
- adamretter 6y agoMany years ago I worked for a BlueChip company in the UK where they had an XML processing application which provided a nation-wide service. When I started, I looked at the code and saw that all XML production was done through concat and substring calls on Java Strings. When I asked why? I was told it was for "performance", yet the system was slow and they frequently introduced bugs in their XML output and processing due to badly written string operations - I didn't stay there all that long!
- michaelhkay 6y agoI flew all the way from London to California once to help a household-name IT company with a perceived XML performance problem, which turned out to be simply that they were constructing the XML document using Java string concatenation rather than using a StringBuilder. In an hour I saved them about $1m worth of hardware spend.