 CREATE  TABLE IF NOT EXISTS `patrimonio` (
   `id_unid_organizacional_nivel1a` INT(11) NOT NULL ,
   `id_so` INT(11) NOT NULL DEFAULT '0' ,
-  `dt_hr_alteracao` DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00' ,
+  `dt_hr_alteracao` DATETIME NOT NULL,
   `te_node_address` VARCHAR(17) NOT NULL ,
   `id_unid_organizacional_nivel2` INT(11) NULL DEFAULT NULL ,
   `te_localizacao_complementar` VARCHAR(100) NULL DEFAULT NULL ,

-- Table `log`
-- -----------------------------------------------------
CREATE  TABLE IF NOT EXISTS `log` (
  `dt_acao` DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00' ,
  `cs_acao` VARCHAR(20) NOT NULL DEFAULT '' ,
  `nm_script` VARCHAR(255) NOT NULL DEFAULT '' ,
  `nm_tabela` VARCHAR(255) NOT NULL DEFAULT '' ,

  `te_node_address` VARCHAR(17) NOT NULL DEFAULT '' ,
  `id_so` INT(10) UNSIGNED NOT NULL DEFAULT '0' ,
  `id_software_inventariado` INT(10) UNSIGNED NOT NULL DEFAULT '0' ,
  `dt_hr_inclusao` DATETIME NOT NULL ,
  `dt_hr_ult_coleta` DATETIME NOT NULL ,
  PRIMARY KEY (`te_node_address`, `id_so`, `id_software_inventariado`, `dt_hr_inclusao`) )
ENGINE = InnoDB
DEFAULT CHARACTER SET = latin1;
