IF EXISTS ( SELECT * 
            FROM   sysobjects 
            WHERE  id = object_id(N'[dbo].[sp_STUD_1_GetReportPrepPage]') 
                   and OBJECTPROPERTY(id, N'IsProcedure') = 1 )
    DROP PROCEDURE [dbo].[sp_STUD_1_GetReportPrepPage]


IF EXISTS (SELECT * FROM   sys.objects
           WHERE  object_id = OBJECT_ID(N'[dbo].[fn_STUD_1_GetPrepEnglishTeachers]')
                  AND type IN ( N'FN', N'IF', N'TF', N'FS', N'FT' ))
	DROP FUNCTION [dbo].[fn_STUD_1_GetPrepEnglishTeachers]

IF EXISTS (SELECT * FROM   sys.objects
           WHERE  object_id = OBJECT_ID(N'[dbo].[fn_STUD_1_GetPrepMathsTeachers]')
                  AND type IN ( N'FN', N'IF', N'TF', N'FS', N'FT' ))
	DROP FUNCTION [dbo].[fn_STUD_1_GetPrepMathsTeachers]

IF EXISTS (SELECT * FROM   sys.objects
           WHERE  object_id = OBJECT_ID(N'[dbo].[fn_STUD_1_GetPrepOtherSubjectTeachers]')
                  AND type IN ( N'FN', N'IF', N'TF', N'FS', N'FT' ))
	DROP FUNCTION [dbo].[fn_STUD_1_GetPrepOtherSubjectTeachers]

