Anonymous interview question

Basic java and SQL questions