SET QUOTED_IDENTIFIER ON 
GO
SET ANSI_NULLS ON 
GO
CREATE VIEW [data].[S_Gesamt_Arbeitstage] AS

SELECT        TOP (100) PERCENT bundeslaender_id AS bid, SUM(arbeitstag_mofr) AS gesamt
FROM            data.Arbeitstage
WHERE        (YEAR(datum) = YEAR(GETDATE()))
GROUP BY YEAR(datum), bundeslaender_id, arbeitstag_mofr
HAVING        (arbeitstag_mofr = 1)
GO
SET QUOTED_IDENTIFIER OFF 
GO
SET ANSI_NULLS OFF 
GO

GO
