fixed database encoding
use mysql_use_result to avoid out-of-memory on large resultset
set time_zone to UTC
Merge pull request #9 from nikicat/master

memory consumption reduced, database encoding fix