Removed duplicate db code

Removed duplicated code that selected database this is now in mysql.inc