Re: extracting data
Posted in 2000
--- "chris" <damoncwk@hotmail.com> > wrote: >Dear all, > If there are 3 relations as shown below: >PreferredTutor(name varchar(40), instructor varchar(40)) >PreferredInstructor(name varchar(40), tutor varchar(40)) >Assignment(courseTitle varchar(40), instructor varchar(40)) > >A tuple(x,y) is in PreferredTutor if an instructor x prefers a tutor y to >work on his course. >A tuple(x,y) is in PreferredInstructor if a tutor x prefers to work for the >instructor y. > >In reality, tutors may not have any preferred instructor to work with. >tutors who do not indicate his preferred instructor and is not preferred by >any instructor will not have his or her name listed in any of the above 3 >tables. Suppose new tables are not allowed to be built, how can I ensure >that all tutor names appear somewhere in the tables? You can't, given the prior statement that ends, "...will not have his or her name listed in any of the above 3 tables." If I am neither preferred by, nor do I prefer a particular instructor/tutor (since it probably works both ways) AND you include a rule that says I can't exist in one of these three tables without a preference for or by an appropriate counterpart AND you specify that no other tables may be created, my name (and others like me) will not appear in any of your existing tables. Unless you allow for a preference of none and a preferred by of none. Don't you have tables that hold instructor/tutor information aside from these preference tables? > >And how can I find the total number of tutors using only the above 3 tables? > Thx a lot! How can you find the total of something you only have subsets of when you're missing one subset that you are certain is exclusive of the other subset(s)? == "Outlook not so good." That magic 8-ball knows everything! I'll ask about Exchange Server next. _____________________________________________________________ Want a new web-based email account ? ---> http://www.firstlinux.net