 -- -----------------------------------------------------
 CREATE TABLE IF NOT EXISTS `db_sigecu`.`pagos` (
   `idpagos` INT(11) NOT NULL AUTO_INCREMENT,
+  `tP_idtipoPago` INT NOT NULL,
   `pCantidad` VARCHAR(45) NULL,
+  `pFecha` DATE NULL,
   `pStatus` INT(11) NULL DEFAULT NULL,
   `hP_idhistorialPagos` INT NOT NULL,
-  `tP_idtipoPago` INT NOT NULL,
   PRIMARY KEY (`idpagos`, `hP_idhistorialPagos`),
   INDEX `fk_pagos_historialPagos1_idx` (`hP_idhistorialPagos` ASC),
   INDEX `fk_pagos_tipoPago1_idx` (`tP_idtipoPago` ASC),

CREATE TABLE IF NOT EXISTS `db_sigecu`.`tipoPago` (
  `idtipoPago` INT NOT NULL AUTO_INCREMENT,
  `tpNombre` VARCHAR(45) NULL,
  PRIMARY KEY (`idtipoPago`))
ENGINE = InnoDB;


-- MySQL Script generated by MySQL Workbench
-- Wed Nov 22 19:22:08 2017
-- Model: New Model    Version: 1.0
-- MySQL Workbench Forward Engineering

