I have a simple query doubt.
Question Table
qid question
1 ques1
2 ques2
3 ques3
4 ques4
5 ques5
6 ques6
7 ques7
Answer Table
ansid qid answer
1 1 ans1
2 2 ans2
3 2 ans3
4 4 ans4
5 6 ans5
I have two tables. One for questions and one for answers. Question id(qid) is use as a foreign key in answer table. I want select questions which doesnot have an answer in the answer table. In the above example I need questions 3,5,7. My database is large it may contain more than 50,000 records.
Thanks
ARun
edit.
Moreover it would be better to add an index on answer table