Tuning the database