I am creating a stored procedure in MS SQL Server 2000. I have a table with ID, Code, Start Date and End Date as the fields.

I want to calculate the date difference between Start and the End date excluding the weekends and display the result in this format: ID | Code | Working_Days.

How do I go about doing that?