Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
azamsharp
Posting Yak Master
201 Posts |
Posted - 2006-08-21 : 17:53:56
|
Hi, I am making a school testing application and I need to show the grades of the students. Now, the grades are written in the database when the student submits the exam. In the grade book the teacher should see all the student and their grades but teacher can also see the students score and grades before they gave the test. In this case the score will be N/A not available. Now, the problem is how do I join from the registeration table which has the student id to a table which does not yet contain any information about the student grade. Thanks, Mohammad Azam www.azamsharp.net |
|
azamsharp
Posting Yak Master
201 Posts |
Posted - 2006-08-21 : 18:00:13
|
I think I have figured it out using the LEFT OUTER JOIN! Please correct me if I am wrong. Mohammad Azam www.azamsharp.net |
 |
|
eyechart
Master Smack Fu Yak Hacker
3575 Posts |
Posted - 2006-08-21 : 18:02:24
|
look up OUTER JOIN in books online (BOL). The outer join will return NULL for values that are missing. You may also want to look into the ISNULL function to change the NULLs to a value that makes a little more sense (something like 'Not Available' for example).-ec |
 |
|
eyechart
Master Smack Fu Yak Hacker
3575 Posts |
Posted - 2006-08-21 : 18:02:54
|
quote: Originally posted by azamsharp I think I have figured it out using the LEFT OUTER JOIN! Please correct me if I am wrong.
you beat me to the punch. You are on the right track.-ec |
 |
|
azamsharp
Posting Yak Master
201 Posts |
Posted - 2006-08-21 : 18:31:12
|
Thanks!Mohammad Azam www.azamsharp.net |
 |
|
|
|
|