-- dbo.ef_Bit2Int
CREATE FUNCTION dbo.ef_Bit2Int (@inBool BIT) RETURNS TINYINT
AS
BEGIN

-- !! funkci neupravujte, bude stejne pregenerovana pri startu pluginu PluginHDCRTN !!

 RETURN CONVERT(tinyint, CASE WHEN @inBool=1 THEN 1 ELSE 0 END)
END