Skip to content

ajpsp5/SE_Fall_2015

Repository files navigation

Tenative Database

Database can change



Queries


Tickets are produced and prepared to be sold to the public.

- Shows all tickets available

select * from tickets;

The competing athletes are notified of the time and place for their competition.

- Check what competition the athlete attends

select g.name as 'Competition', g.id as 'Competition_id', g.time, g.location_name from athletegamerelationship agr inner join athletes a on agr.athlete = a.id inner join games g on agr.game = g.id where a.id = {Athlete ID};

- Save Notification from the above query

insert into notifications (message, type)values('Your Event {Event Name} is at {Event Time & Date} in {Event Location}', 'R');

"R" means Reminder

- Save Game Notification Relationship

insert into gamenotificationsrelationship (game, notification) values({Game ID}, {Notification ID});

The Security department is notified to provide security guards and the necessary security equipment.

- Create Message for Security

insert into notifications (message, type)values('Security Guards are needed at {Event Name}', 'S');

"S" means Security

- Save Game Notification Relationship

insert into gamenotificationsrelationship (game, notification, securityMessage) values({Game ID}, {Notification ID}, 'Y');

The medals ceremonies are scheduled.

- Get all scheduled ceremonies

select * from ceremonies where date(date)>=date(NOW());

Q/A

Give me any question I will give an answer
2 Years of enterprise web application development, over a year of creating document management software and database architecture

Check if someone is family of athlete

select afr.id from athletefamilymemberrelationship afr inner join athlete a on a.id = afr.athlete inner join familymember f on f.id = afr.familyMember where afr.active = 'Y' and a.id = {Athelete ID} and f.firstName = '{First Name}' and f.lastName = '{Last Name}';

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published