Bugfix and added MILLISECOND support for MySQL