General information
Category:
Databases,Tables, Views, Indexing and SQL syntax
>I have table "merit.dbf" having fields 1. Regno 2. Applno 3. Category 4. dob 5. Physics 6. chemistry 7. Biology.
> I want to select the record whose students age >= 17 years as on 31.12.2009.(These students are eligible for courses like M.B.B.S, BDS,B.V.Sc, BAMS, AND B.Sc(NURSING)). The sample data image is send herewith for reference. Awaiting yours valuable reply.
Before dealing with the specific SQL command the first thing you need to do is normalize the data.
First you need a table of applicants. If you know Applno is unique you can use that. Otherwise use an autogenerated sequential primary key.
You probably also need a Registration table, with a relation to Applicants. I imagine some applicants apply more than once so be sure to capture the details of each.
You need another table for test scores. Again it should have a child key to the applicant. Do not wire it to biology, physics, and chemistry. Make it generic, just a test score associated with a test and a registered applicant.
To keep it clean you should have a reference table of tests.
The Select statement will fall into place once you have those things straightened out.
A field called Caste, hmmm.
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only