By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,210 Members | 1,490 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,210 IT Pros & Developers. It's quick & easy.

create new fields

P: n/a
It seems a little odd to think about adding fields to a table, but I'm
trying to put something together to help me with my marking ... a teacher!
A table represents a mark sheet and i want to add new field each time I do a
session of marking. (The data is then stored and printed on labels) I
can't create the fields first of all because I don't know whather the next
lot of marking will be a number or a memo field. Is it reasonable to add
them as I go along, and if so, how do i do it?
Nov 13 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Any reason you cant have something like this?

CREATE TABLE Student(
StudentID Long PRIMARY KEY,
FirstName Text(20) NOT NULL,
LastName Text(30) NOT NULL,
....
)

CREATE TABLE Test(
TestID Autonumber,
TestDate Date,
Weight Single,
....)

CREATE TABLE StudentTest(
TestID LONG,
StudentID LONG,
Score Single,
PRIMARY KEY (TestID, STudentID),
FOREIGN KEY TestID REFERENCES Test(TestID),
STudentID REFERNCES STudent(StudentID)
);

Then you can just add a new Test record every time you add a test and
then keep your data normalized. You should be able to get all the
current averages and all that stuff without a problem...

HTH,
Pieter

Nov 13 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.