3: Database Design in VS .NET

Printing QR Code in VS .NET 3: Database Design

3: Database Design
QR Generator In .NET
Using Barcode creation for Reporting Service Control to generate, create QR Code image in Reporting Service applications.
Barcode Encoder In VS .NET
Using Barcode creator for Reporting Service Control to generate, create barcode image in Reporting Service applications.
Database Design Exercise
Generating QR Code 2d Barcode In Visual C#
Using Barcode maker for .NET Control to generate, create Denso QR Bar Code image in VS .NET applications.
Creating Denso QR Bar Code In Visual Studio .NET
Using Barcode creator for ASP.NET Control to generate, create QR Code image in ASP.NET applications.
When teaching SQL in the classroom, I often use this scenario to help people move from the theoretical into the concrete Instead of just thinking about how a database may be designed, we actually do it While a possible solution is provided at the end of the exercise, I strongly encourage you to try and solve the problem on your own before looking at the solution
Encoding QR Code JIS X 0510 In VS .NET
Using Barcode drawer for .NET Control to generate, create QR Code JIS X 0510 image in Visual Studio .NET applications.
QR Code JIS X 0510 Encoder In VB.NET
Using Barcode maker for .NET Control to generate, create QR Code JIS X 0510 image in Visual Studio .NET applications.
The Scenario
Drawing Bar Code In Visual Studio .NET
Using Barcode drawer for Reporting Service Control to generate, create bar code image in Reporting Service applications.
Painting USS-128 In .NET
Using Barcode generator for Reporting Service Control to generate, create UCC.EAN - 128 image in Reporting Service applications.
Imagine you are tasked with designing the database for an online testing site for practice tests Someone else is designing the web site and will handle data entry Your task is just to design the database The application will be used by:
Generate EAN13 In .NET Framework
Using Barcode generation for Reporting Service Control to generate, create EAN / UCC - 13 image in Reporting Service applications.
ECC200 Generation In .NET
Using Barcode encoder for Reporting Service Control to generate, create Data Matrix ECC200 image in Reporting Service applications.
Program administrators Test administrators answers
Painting Code 128 In .NET
Using Barcode maker for Reporting Service Control to generate, create Code-128 image in Reporting Service applications.
USS Code 39 Encoder In .NET
Using Barcode generator for Reporting Service Control to generate, create Code 39 image in Reporting Service applications.
Those who administer the database and program
EAN 8 Drawer In VS .NET
Using Barcode maker for Reporting Service Control to generate, create EAN 8 image in Reporting Service applications.
Draw UPCA In VS .NET
Using Barcode maker for ASP.NET Control to generate, create GTIN - 12 image in ASP.NET applications.
Those who create tests composed of test questions and
Scanning ANSI/AIM Code 39 In None
Using Barcode reader for Software Control to read, scan read, scan image in Software applications.
EAN 128 Drawer In VB.NET
Using Barcode printer for .NET Control to generate, create UCC - 12 image in VS .NET applications.
Test takers Those who take tests
Making Barcode In VB.NET
Using Barcode encoder for Visual Studio .NET Control to generate, create barcode image in .NET applications.
UPC-A Supplement 2 Drawer In Objective-C
Using Barcode maker for iPhone Control to generate, create GS1 - 12 image in iPhone applications.
The site will have multiple tests in multiple categories For example, you could have a 70-431 test, a 70-441 test, and a 70-442 test all in the MCITP category Each test would have a variable number of test questions, and each question would have an explanation (explaining why a test question was incorrect) and a reference Every question will have multiple answers (two for True/False and a variable number for multiple choice questions) The correct answer for each test question must be identified You must store history data for anyone who takes the test These test history data will show the following for each test taken: which test was taken, who took it, when they took it, and their score Again, your job is not to create the application that uses the database, or even to create the data that goes into the database All you need to do is design the database However, an effective design will make the creation of the application much easier Using the previous paragraphs, determine the design Use a pencil and paper to draw and label the tables Identify the columns within each table Use lines to identify relationships between the tables and identify PRIMARY KEYs and FOREIGN KEYs As a hint, my database solution uses seven tables If you haven t created any tables yet, try to produce the answer with at least seven tables There is no single correct answer, so your solution may look slightly different from mine The goal isn t to make sure you think like me, but to instead get you to think through the design of a database
Make GTIN - 13 In Java
Using Barcode drawer for Java Control to generate, create EAN13 image in Java applications.
Create USS Code 39 In VB.NET
Using Barcode creation for .NET framework Control to generate, create Code-39 image in .NET applications.
The Solution
You have finished the exercise, haven t you No peeking until you ve given it your best effort
MCITP SQL Server 2005 Database Developer All-in-One Exam Guide
Hint
If you re stuck and unsure how to start, take a look at the explanation for creating the first two tables Based on the knowledge you gain from creating these two tables, try to create the rest of the database design on your own As a hint, my solution uses seven tables
Creating the Person and Roles Tables
To start, read the first paragraph with the following bullets: The application will be used by: Program administrators Test administrators answers Test takers Those who administer the database and program
Those who create tests composed of test questions and
Those who take tests
This tells me to create a user table Since the word USER is a reserved word in SQL Server 2005, we could instead call it a Person table The Person table might look like Figure 3-21
Figure 3-21 The Person table for the TestMaker database
Since we only have three roles, we could instead create a Role table and relate it to the Person table This would prevent anyone from entering anything other than the three roles, or from shortening the roles to something else such as Test Admin instead of Test Administrator These two tables would look like Figure 3-22
Figure 3-22 The Person and Roles tables related on the RoleID
The first column I d create in any table is the PRIMARY KEY It s common to name this by adding a suffix of ID to the name of the table We d then create a relationship between the two tables using the RoleID column The rest of the data would be determined by the given requirements You may choose to add additional columns to the Person table such as Password, Email, Phone, or more, but the preceding tables will satisfy the basic requirements of the scenario
Copyright © OnBarcode.com . All rights reserved.