Use SQL Server Management Studio finished
According to 'AssessmentGuide's instructions and requirements
Answer 'DesignDocument Race Entry's questions(some questions can prt sc the picture)
Contribute Materials
Your contribution can guide someone’s learning journey. Share your
documents today.
i TRA Race Entry System Author: Name + Number Teesside University Design Document Systems Design and Databases
Secure Best Marks with AI Grader
Need help grading? Try our AI Grader for instant feedback on your assignments.
1DATA MODEL 1.1UML CLASS DIAGRAM – CONCEPTUAL MODEL The following model shows… Figure1: UML Conceptual Class Diagram 1.2DATA DICTIONARY The following data dictionary definition is for the operation which calculates the race entrant’s points. … For each member For each race Points =+ Race_outcome.points Print member.name + points End for loop 2SEQUENCE DIAGRAM FOR RACE REGISTRATION 1
Figure2: Sequence Diagram for Race Entry 3UML CLASS DIAGRAM – IMPLEMENTATION MODEL The following diagram shows….
Paraphrase This Document
Need a fresh take? Get an instant paraphrase of this document with our AI Paraphraser
age_typeVarchar(200), memershipCHAR(4), fees_amountDECIMAL(12,2), PRIMARYKEY(race_id,age_type,memership), CONSTRAINTFK_RaceFeesFOREIGNKEY(race_id)REFERENCESRace(race_id) ); CreatetableRace_Outcome( member_idINT, race_idINT, positionINT, categoryCHAR(4), pointsINT, PRIMARYKEY(race_id,member_id), CONSTRAINTFK_RaceFOREIGNKEY(race_id)REFERENCESRace(race_id), CONSTRAINTFK_MemberFOREIGNKEY(member_id)REFERENCESMember(member_id) ); 5SQL QUERIES 5.1QUERY 1 Build a list of races that the specified member has not already entered. select [dbo].[Race].* from [dbo].[Race] LEFT JOIN [dbo].[Race_Outcome] On [dbo].[Race].[race_id] = [dbo].[Race_Outcome].[race_id] WHERE [dbo].[Race_Outcome].[race_id] IS NULL; 5.2QUERY 2 Insert a new race entry into the database. Insert Into [dbo].[Race] values (1, 'SDD Race 3 at High Hill', '10.00 – 10.30', '10:45:00', 267578, '6km', 'Exposed open hillside, mainly footpaths but some open fields on lower slopes', '2012-12-16'); Insert Into [dbo].[Fees] Values (1, 'senior', 'Yes', 5.00); Insert Into [dbo].[Fees] Values (1, 'junior and veterans', 'Yes', 3.00); Insert Into [dbo].[Fees] Values (1, 'senior', 'No', 7.00); Insert Into [dbo].[Fees] Values (1, 'junior and veterans', 'No', 5.00); 5.3QUERY 3
The purpose of this query is to count the total number of points for every member Select [member_name], SUM([points]) AS TotalPoint From [dbo].[Member] Inner Join [dbo].[Race_Outcome] ON [dbo].[Member].[member_id] = [dbo].[Race_Outcome].[member_id] Group By [member_name]; 5.4QUERY 4 The purpose of this query generate a list of entries for all races (raceid, venue, date, bib num, member name, age cat at time of entry, club at time of entry, position, points) Select * from [dbo].[Member] Inner Join [dbo].[Race_Outcome] ON [dbo].[Member].[member_id] = [dbo].[Race_Outcome].[member_id] Inner Join [dbo].[Race] ON [dbo].[Race_Outcome].[race_id] = [dbo].[Race].[race_id] Inner Join [dbo].[Fees] On [dbo].[Race].[race_id] = [dbo].[Fees].[race_id];