Tavant interview question

MySQL java puzzless