I have a table "Student" in sql with a structure:
StudentId FirstName LastName
1 X Y
....
AND a table of Languages ,its structure:
LanguageId Name
1 English
2 Mandarin
3 Spanish
.....
and a relationship table StudentLanguage (languages spoken by a student)
StudentId LanguageId
1 1
1 3
2 1
2 2
from my asp.net page i want to filter students by spoken languages using checkboxes.
for example,when i check English,Madarin i want to have students speaking both English and Madarin When i check French,Spanish ,English ==>Get students speaking French,AND English,AND Spanish.
to do that i pass a table of Languages paramter called @LanguageTable(LanguageId smallint) to a stored procedure.
how can i use this table to get the students without using a cursor.
I have tried with CTE but no result.