Scenario: I have 2 gridviews, clientgridview for showing the clients and the projectgridview for showing the projects. If I Click on the Client name on the the clientgridview i will be directed to the project gridview to show the different projects of the client
Problem: when i click on the name of my client, projectgridview displays all the projects that are stored on my database. I need to display only the projects that are associated to the selected client(ProjectId is the PK in m ProjectTable and is FK in ClientTable).
Can anyone help me get the corrent syntax to filter the projectId...
SELECT * FROM Project WHERE ProjectId=@Project;
I used this syntax and it didnt work..hope you guys can figure out how to filter this correctly..