<div class="gmail_quote">On 3 July 2011 12:02, Dave Cross <span dir="ltr">&lt;<a href="mailto:dave@dave.org.uk">dave@dave.org.uk</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<br>I have a MySQL db where all the tables contain UTF8 data. Actually, as far as I can see, the only problematic character is the £ sign.<br><br>
My DBIC connect looks like this:<br>
<br>
my $sch = MyData::DB-&gt;connect(<br>
  &#39;dbi:mysql:database=mydata;&#39;,<br>
  &#39;user&#39;, &#39;xxxx&#39;, { mysql_enable_utf8 =&gt; 1 }<br>
);<br>
<br></blockquote><div>Looking at</div><div><a href="https://github.com/dbsrgits/dbix-class/blob/master/lib/DBIx/Class/Storage/DBI/mysql.pm">https://github.com/dbsrgits/dbix-class/blob/master/lib/DBIx/Class/Storage/DBI/mysql.pm</a></div>
<div><br></div><div>it doesn&#39;t look like it does a SET NAMES utf8; on initial connection and you&#39;re not using an on_connect_do to set it so unless your mysql db conf is set to default you might get issues?</div><div>
Maybe worth using strict mode too :-\</div><div><br></div><div>Regards, Peter</div><div><a href="http://perl.dragonstaff.co.uk">http://perl.dragonstaff.co.uk</a></div><div><br></div><div><br></div><div><br></div><div><a href="http://dev.mysql.com/doc/refman/5.0/en/charset-unicode.html">http://dev.mysql.com/doc/refman/5.0/en/charset-unicode.html</a></div>
<div><br></div><div> </div></div>