IF EXISTS(SELECT 1 FROM [dbo].[estipulante] WHERE [idempresa] IS NULL) BEGIN UPDATE [estipulante] SET [idempresa] = 1 WHERE [idempresa] IS NULL; END