Base64 encode/decode loses string encoding, which may end up as ASCII-8BIT, which doesn't combine well with non-ASCII SQL strings while logging.