I have 3 tables
Student Loan Book
- StudentID LoanID BookID
which foreign keys do i need to set so when given the student name, search all loan from that student and display the book detail
I have 3 tables
Student Loan Book
- StudentID LoanID BookID
which foreign keys do i need to set so when given the student name, search all loan from that student and display the book detail
Not sure what columns you have, assuming you have studentId in student table, it would be best candidate for primary in Student and foriegn in other two tables.
you have to use studentid as foreign key in both the other tables...because you want to search on the basis of student. so this key should go in the remaining tables
Here's a start with such vague requirements: