Hi All,
I am trying to find a way to use a stored procedure to filter out the records i do not want rather than in my program.
I have a list of shifts that are linked to a piece of equiptment, which has an equiptmentID.
I have a table that links workerID's to what equiptment they can work.
I can query the shifts table and select shifts between 2 given dates. within this query the SquiptmentID is obtained.
Is there a way for me to add the workerID into the same SP and have it remove all the entries where the equiptmentID is not linked to the staffID?
I imagine this might sound confusing, but any help will be very welcome.
Thanks
John
I am trying to find a way to use a stored procedure to filter out the records i do not want rather than in my program.
I have a list of shifts that are linked to a piece of equiptment, which has an equiptmentID.
I have a table that links workerID's to what equiptment they can work.
I can query the shifts table and select shifts between 2 given dates. within this query the SquiptmentID is obtained.
Is there a way for me to add the workerID into the same SP and have it remove all the entries where the equiptmentID is not linked to the staffID?
I imagine this might sound confusing, but any help will be very welcome.
Thanks
John