CREATE TABLE `quotes` (
`text` varchar(255) NOT NULL
) ENGINE=MyISAM DEFAULT CHARSET=utf8
####
INSERT INTO `test`.`quotes` (
`text`
)
VALUES (
'“” ‘’'
);
####
mysql> select * from quotes where 1;
+----------------+
| text |
+----------------+
| “” ‘’ |
+----------------+
mysql> select hex(text) from quotes where 1;
+----------------------------------+
| hex(text) |
+----------------------------------+
| E2809C E2809D 2020 E28098 E28099 |
+----------------------------------+
## just so we know exactly what bytes are in there, my spacing
####
#!/usr/local/bin/perl
use utf8;
use strict;
use DBI;
my $dbh =
DBI->connect( 'DBI:mysql:test:localhost', 'root', 'xxxxxxxx' )
or die("couldn't connect to database");
my $text_display = $dbh->prepare('select * from quotes where 1');
$text_display->execute();
my ($text) = $text_display->fetchrow_array();
print "Text: $text" . $/;
####
Text: ?? ??
####
Text: ìî ëí