USE [dbVARK]
GO

/****** Object:  Trigger [dbo].[AktiviranjeKod]    Script Date: 30.12.2015 03:28:01 ******/
SET ANSI_NULLS ON
GO

SET QUOTED_IDENTIFIER ON
GO


CREATE TRIGGER [dbo].[AktiviranjeKod]
    ON [dbo].[Administratori]
    AFTER INSERT
    AS
    BEGIN
    SET NOCOUNT ON
	UPDATE [dbo].[AdminKod]
	SET Aktiviran = 'true'
	WHERE Kod = (SELECT Verifikaciski_Kod FROM inserted)
    END

GO

