Parcourir la source

create bag db, remove equipment_type

master
CANCERYS\kw093 il y a 9 heures
Parent
révision
a02b7b923a
2 fichiers modifiés avec 63 ajouts et 0 suppressions
  1. +59
    -0
      src/main/resources/db/changelog/changes/20251216_01_Enson/01_add_column.sql
  2. +4
    -0
      src/main/resources/db/changelog/changes/20251217_01_Enson/01_drop_table.sql

+ 59
- 0
src/main/resources/db/changelog/changes/20251216_01_Enson/01_add_column.sql Voir le fichier

@@ -0,0 +1,59 @@
-- liquibase formatted sql
-- changeset Enson:add_column

create table `fpsmsdb`.`bag` (
`id` int not null auto_increment,
`itemId` int not null,
`itemCode` varchar(255) not null,
`itemName` varchar(255) not null,
`takenBagBalance` int not null,
`created` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
`createdBy` varchar(30) DEFAULT NULL,
`version` int NOT NULL DEFAULT '0',
`modified` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
`modifiedBy` varchar(30) DEFAULT NULL,
`deleted` tinyint(1) NOT NULL DEFAULT '0',
primary key (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

create table `fpsmsdb`.`bag_lot_line` (
`id` int not null auto_increment,
`bagId` int not null,
`lotId` int not null,
`lotNo` varchar(255) not null,
`firstUseDate` datetime not null,
`lastUseDate` datetime not null,
`startQty` int not null,
`consumedQty` int not null,
`scrapQty` int not null,
`balanceQty` int not null,
`created` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
`createdBy` varchar(30) DEFAULT NULL,
`version` int NOT NULL DEFAULT '0',
`modified` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
`modifiedBy` varchar(30) DEFAULT NULL,
`deleted` tinyint(1) NOT NULL DEFAULT '0',
primary key (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

create table `fpsmsdb`.`jo_bag_consumption` (
`id` int not null auto_increment,
`bagId` int not null,
`bagLotLineId` int not null,
`jobId` int not null,
`jobOrderCode` varchar(255) not null,
`startQty` int not null,
`consumedQty` int not null,
`scrapQty` int not null,
`endQty` int not null,
`date` datetime not null,
`time` datetime not null,
`created` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
`createdBy` varchar(30) DEFAULT NULL,
`version` int NOT NULL DEFAULT '0',
`modified` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
`modifiedBy` varchar(30) DEFAULT NULL,
`deleted` tinyint(1) NOT NULL DEFAULT '0',
primary key (`id`)

) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

+ 4
- 0
src/main/resources/db/changelog/changes/20251217_01_Enson/01_drop_table.sql Voir le fichier

@@ -0,0 +1,4 @@
-- liquibase formatted sql
-- changeset Enson:add_column

DROP TABLE IF EXISTS `fpsmsdb`.`equipment_type`;

Chargement…
Annuler
Enregistrer