﻿IF (object_id( 'Permissao' ) IS NOT NULL)
BEGIN
    IF NOT EXISTS(SELECT 1 FROM [dbo].[Permissao] WHERE [idpermissao] = 0)
    BEGIN
	    SET IDENTITY_INSERT Permissao ON 
        INSERT INTO Permissao (idpermissao,Nome,Tipo) VALUES (0,'Sem Acesso',0)
        SET IDENTITY_INSERT Permissao OFF
    END
END