[ticket/10966] Introduce MySQL base class 

http://tracker.phpbb.com/browse/PHPBB3-10966