There is such a query to the database MySql

select FirstName, LastName, runner.Email, RegistrationStatus from registrationevent inner join registration on registration.RegistrationId = registrationevent.RegistrationId inner join registrationstatus on registration.RegistrationStatusId = registrationstatus.RegistrationStatusId inner join runner on runner.RunnerId = registration.RunnerId inner join user on user.Email = runner.Email inner join event on event.EventId = registrationevent.EventId inner join eventtype on event.EventTypeId = eventtype.EventTypeId where RegistrationDateTime like '%2017%' and EventTypeName='Full Marathon' 

Everything is done in such a database

Can it be simplified? And if so, how?

  • It depends on what you mean by the word "simplify". - Vanya Avchyan
  • Add what you did yourself and what happens - Vadim Prokopchuk
  • It seems like no. All tables are needed ... - MihailPw
  • I would combine the tables Runner and User , they are broken illogical. And there is nothing to simplify in the request. - Mirdin
  • Well, this is an Olympiad task, so I do not know whether they can be connected or not. But thanks for the replies :) - Danilolegovich2

0