We're finding that, when working with the em dash character, the LEFT and
LENGTH functions don't work well together. This query shows trying to
strip off the last character from a string containing an em dash:
mysql> select LEFT('031492349−0002,', LENGTH('031492349−0002,') - 1),
LENGTH('031492349−0002,'), LENGTH('031492349-0002,');
+------------------------------------------------------------+-----------------------------+---------------------------+
| LEFT('031492349−0002,', LENGTH('031492349−0002,') - 1) |
LENGTH('031492349−0002,') | LENGTH('031492349-0002,') |
+------------------------------------------------------------+-----------------------------+---------------------------+
| 031492349−0002, |
17 | 15 |
+------------------------------------------------------------+-----------------------------+---------------------------+
1 row in set (0.06 sec)
Is this a bug? If it's a "feature", what could we do instead to get around
this issue?
Thanks,
Robert Voliva