473,659 Members | 2,680 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Need to normalize to 2nd form.

jim
So I've had my knuckles rapped by a pro who can offer only vauge
advice. I need to reduce the size of one of my tables.

Here is the scene:
I'm trying to track lots of test scores for individual middle school
students.

I have a student info table using a student ID number as a primary key.

The columns in this table are:

The Usual-
First Name
Last Name
Gender
Phone
etc.

But Also:
Test Score #1
Test Score #2
Test Score #3
Test Score #4
Test Score #5
etc.

Other Columns are populated automatically by selections from combo
boxes in a form. The combo boxes get thier information from seperate
tables. The columns that are populated by other tables are:
Ethnicity
6th grade Math teacher
7th grade Math teacher
etc.

It seems to me that individual test scores are tied uniquely to the
student ID and therefore should be right in the Student info table.

Perhaps my cosultant meant that I should not be populating those
columns (Ethnicity, teachers) with text but perhaps with some other
kind of link to the other tables?

I'm a noob seeking advice here.
Thanks for any help.

Oct 5 '06 #1
4 1996
The test scores are tied to a student, but they also apply for a test:

StudentTable
------------
StudentID
FirstName
LastName
etc.

TestTable
--------------
TestID
TestDate
etc.

StudentTestScor es
----------------------------
StudentID
TestID
Score

Chris
jim wrote:
So I've had my knuckles rapped by a pro who can offer only vauge
advice. I need to reduce the size of one of my tables.

Here is the scene:
I'm trying to track lots of test scores for individual middle school
students.

I have a student info table using a student ID number as a primary key.

The columns in this table are:

The Usual-
First Name
Last Name
Gender
Phone
etc.

But Also:
Test Score #1
Test Score #2
Test Score #3
Test Score #4
Test Score #5
etc.

Other Columns are populated automatically by selections from combo
boxes in a form. The combo boxes get thier information from seperate
tables. The columns that are populated by other tables are:
Ethnicity
6th grade Math teacher
7th grade Math teacher
etc.

It seems to me that individual test scores are tied uniquely to the
student ID and therefore should be right in the Student info table.

Perhaps my cosultant meant that I should not be populating those
columns (Ethnicity, teachers) with text but perhaps with some other
kind of link to the other tables?

I'm a noob seeking advice here.
Thanks for any help.
Oct 5 '06 #2
Jim,

Check out the great paper of Paul Litwin's that I've got (with his
permission) on my web site:
http://abcdataworks.com/fundamentals.htm. That will give you the
reason's for doing what the consultant was talking about, and will help
you get to the individual decisions you'll have to make.

For the tests portion of what you're dealing with, you want to avoid
repeating columns in your table--you don't want to have to redesign
your table every time there's a new test. To handle this, you make a
separate table for the test results. That table would have just the
student ID (hopefully there's an autonumber field that serves this
purpose in the student table), the Test Name or Test ID (I'll get to
that in a second), and the test score.

If you store other data on the tests other than the name of the test,
you'll want a third table, which would have all of th einfomration that
describes the test, but not the scores. Basically you would end up with
one table that describes students, one that describes tests, and one
that describes scores.

All of this will make perfect sense after reading Paul's document,
though.

Jeremy Wallace
Application Architect
Fund for the City of New York
jim wrote:
So I've had my knuckles rapped by a pro who can offer only vauge
advice. I need to reduce the size of one of my tables.

Here is the scene:
I'm trying to track lots of test scores for individual middle school
students.

I have a student info table using a student ID number as a primary key.

The columns in this table are:

The Usual-
First Name
Last Name
Gender
Phone
etc.

But Also:
Test Score #1
Test Score #2
Test Score #3
Test Score #4
Test Score #5
etc.

Other Columns are populated automatically by selections from combo
boxes in a form. The combo boxes get thier information from seperate
tables. The columns that are populated by other tables are:
Ethnicity
6th grade Math teacher
7th grade Math teacher
etc.

It seems to me that individual test scores are tied uniquely to the
student ID and therefore should be right in the Student info table.

Perhaps my cosultant meant that I should not be populating those
columns (Ethnicity, teachers) with text but perhaps with some other
kind of link to the other tables?

I'm a noob seeking advice here.
Thanks for any help.
Oct 5 '06 #3
jim
Great. It's nice to have a moment of clarity about this.
I guess I was thrown off because it seems like there is redundancy in
the table that describes the scores (the last one of the three in this
post) as it uses columns that exist in two other tables. I was trying
to make everything appear just once throughout the database.

Jeremy, you said
separate table for the test results. That table would have just the
student ID (hopefully there's an autonumber field that serves this
purpose in the student table)...
I am importing student data into the student table. Each student comes
with a unique ID number to use as a key. I guess I know how to link
tables but how do I get the student ID from the Student table to
populate the The student ID column in the test table. Or should I start
a new thread for that?

Thanks to you both. That was awsome.

Jim
To handle this, you make a
separate table for the test results. That table would have just the
student ID (hopefully there's an autonumber field that serves this
purpose in the student table), the Test Name or Test ID (I'll get to
that in a second), and the test score.

Basically you would end up with
one table that describes students, one that describes tests, and one
that describes scores.

Jeremy Wallace
Application Architect
Fund for the City of New York

StudentTable
------------
StudentID
FirstName
LastName
etc.
TestTable
--------------
TestID
TestDate
etc.
StudentTestScor es
----------------------------
StudentID
TestID
Score

Oct 5 '06 #4
Jim,

You can write an append query to move data from one table to another.
(And yes, your unique student ID is a fine key). Once you're done doing
that, you can drop those test fields from the student table.

Jeremy
--
Jeremy Wallace
Fund for the City of New York

jim wrote:
>
I am importing student data into the student table. Each student comes
with a unique ID number to use as a key. I guess I know how to link
tables but how do I get the student ID from the Student table to
populate the The student ID column in the test table. Or should I start
a new thread for that?

Thanks to you both. That was awsome.
Oct 6 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
4145
by: Christos TZOTZIOY Georgiou | last post by:
I found at least one case where decombining and recombining a unicode character does not result in the same character (see at end). I have no extensive knowledge about Unicode, yet I believe that this must be a problem of the Unicode 3.2 specification and not Python's. However, I haven't found out how the decomp_data (in unicodedata_db.h) is built, and neither did I find much more info about the specifics of Unicode 3.2. I thought about...
5
33300
by: Alex Vassiliev | last post by:
Hi all. Just wanted to share two handy RegEx expressions to strips leading and trailing white-space from a string, and to replace all repeated spaces, newlines and tabs with a single space. * JavaScript example: String.prototype.trim = function() { // Strip leading and trailing white-space
1
6015
by: Daniel Lim | last post by:
When using XmlSerializer, I notice that it does not normalize the single quote and double quote characters, i.e. does not change ' to ' and " to &quot. However, it does normalize other characters, like changing ampersand to & Here is my code: ---- start of code -------- MyClass *myClass = MyClass() ; XmlSerializer *xs = new XmlSerializer( __typeof( MyClass ) ) ;
4
1921
by: Nathan Benefield | last post by:
I currently have a spreadsheet tracking votes on legislation in a matrix type format. It is something like this Name Act1 Veto1 Act1A Jones yes No Yes Johnson Yes Yes Ex. Only with many more members and bills. I want to normalize this so that i can create reports by both Bill and by member - linking it to tables
1
7595
by: jandhondt | last post by:
IN Visual Studio 2005 with VB.NET when I open a solution I often get this warning: The line endings in the following file are not consistent. Do you want to normalize the line endings? The warning occurs on an inherited form. My solution is under Source control with Visual Sourcesafe. No matter if I answer Yes or no, the next time it will still ask this. Does anyone know how to avoid this?
1
1794
by: raylegendkiller | last post by:
NEED TO MAKE A PROGRAM which computes the current value of the vectors {x} based on the following forward iterations: this >>> {x}(n+1) = {x}(n), n = 0,1,2, ... ,8,9. In other words, the next vector {x} is equal to the product of and the current vector {x}. Perform the matrix multiplication by using the function:
4
2719
by: kollatjorva | last post by:
Hi all I'm trying to get a value from an xml node 'Publisher' use the value as a name of an .css class. This works fine until I get a value from the Publisher node with white space in it. I've been trying to use normalize-space function on this but I can't make this work here is what I'm trying to do
13
2193
by: WardC | last post by:
I'm a FileMaker user trying to help a client with an Access data entry problem: When text is copied from another application and pasted into an Access form, the pasted text sometimes includes unwanted characters (e.g., leading or trailing whitespace, embedded carriage returns, punctuation). We'd like to automatically normalize the pasted text. I know how I'd do this in FileMaker - perform an Auto-Enter calculation that replaces the newly...
8
2998
by: bbcrock | last post by:
I have three tables with a relationship I've never worked with before. Can anyone suggest/comment on the best way to create a third normal form relationship between these tables? The tables basically are: TRAIN (TRAIN_ID and 15 columns about train specs, etc) TRUCK (TRUCK_ID and 12 columns about truck specs, etc) TRANSPORTATION_ITEM This table has, among others, two columns, TRUCK_ID and TRAIN_ID. If
0
8427
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8851
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8746
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8525
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7356
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5649
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4175
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2750
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1975
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.