-- --------------------------------------------------------
-- 主機:                           127.0.0.1
-- 伺服器版本:                        10.7.3-MariaDB - mariadb.org binary distribution
-- 伺服器作業系統:                      Win64
-- HeidiSQL 版本:                  12.0.0.6507
-- --------------------------------------------------------

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET NAMES utf8 */;
/*!50503 SET NAMES utf8mb4 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

-- 傾印  資料表 cmes.f10-e1 結構
DROP TABLE IF EXISTS `f10-e1`;
CREATE TABLE IF NOT EXISTS `f10-e1` (
  `SubstrateNum` varchar(30) NOT NULL,
  `WaferNum` varchar(25) DEFAULT NULL,
  `LOTNum` varchar(20) DEFAULT NULL,
  `WorkID` varchar(8) DEFAULT NULL,
  `TimeStamp_Start` timestamp NULL DEFAULT current_timestamp(),
  `TimeStamp_End` timestamp NULL DEFAULT NULL,
  `WaferSize` float unsigned DEFAULT 1,
  `Judgement` varchar(20) DEFAULT NULL,
  `Comment` text DEFAULT NULL,
  `locked` tinyint(1) NOT NULL DEFAULT 0,
  `AVG_PL1` float DEFAULT NULL,
  `STD_PL1` float DEFAULT NULL,
  `Int_PL1` float DEFAULT NULL,
  `Strain1` float DEFAULT NULL,
  `ModelNum` varchar(30) DEFAULT NULL,
  `PGroup` varchar(30) DEFAULT NULL,
  PRIMARY KEY (`SubstrateNum`),
  UNIQUE KEY `f10_e1_WaferNum_IDX` (`WaferNum`),
  KEY `r10_e1_FK` (`WorkID`) USING BTREE,
  KEY `r10_e1_FK_1` (`LOTNum`) USING BTREE,
  KEY `r10_e1_TimeStamp_Start_IDX` (`TimeStamp_Start`) USING BTREE,
  CONSTRAINT `f10_e1_FK` FOREIGN KEY (`WorkID`) REFERENCES `employee` (`WorkID`),
  CONSTRAINT `f10_e1_FK_1` FOREIGN KEY (`LOTNum`) REFERENCES `lot_info` (`LOTNum`),
  CONSTRAINT `f10_e1_FK_2` FOREIGN KEY (`SubstrateNum`) REFERENCES `substrate_info` (`SubstrateNum`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

-- 正在傾印表格  cmes.f10-e1 的資料：~9 rows (近似值)
INSERT INTO `f10-e1` (`SubstrateNum`, `WaferNum`, `LOTNum`, `WorkID`, `TimeStamp_Start`, `TimeStamp_End`, `WaferSize`, `Judgement`, `Comment`, `locked`, `AVG_PL1`, `STD_PL1`, `Int_PL1`, `Strain1`, `ModelNum`, `PGroup`) VALUES
	('XYS21602-087', 'A2401R1D', 'FT0002', '0056', '2022-05-23 07:35:29', '2022-05-23 08:51:28', 1, 'PASS', NULL, -1, NULL, NULL, NULL, NULL, 'TR150-00', 'QCL-DFB'),
	('XYS21602-091', NULL, 'FT0002', '0056', '2022-05-23 07:35:34', NULL, 1, NULL, NULL, 0, NULL, NULL, NULL, NULL, 'TR150-00', 'QCL-DFB'),
	('XYS21602-096', NULL, 'FT0002', '0056', '2022-05-23 07:35:40', NULL, 1, NULL, NULL, 0, NULL, NULL, NULL, NULL, 'TR150-00', 'QCL-DFB'),
	('XYS21602-097', NULL, 'FT0002', '0056', '2022-05-23 07:35:44', NULL, 1, NULL, NULL, 0, NULL, NULL, NULL, NULL, 'TR150-00', 'QCL-DFB'),
	('XYS21602-098', NULL, 'FT0003', '0056', '2022-05-23 07:36:00', NULL, 1, NULL, NULL, 0, NULL, NULL, NULL, NULL, 'TR150-00', 'QCL-DFB'),
	('XYS21990-044', NULL, 'FT0001', '0056', '2022-05-23 07:35:06', NULL, 1, NULL, NULL, 0, NULL, NULL, NULL, NULL, 'TR150-00', 'QCL-DFB'),
	('XYS21990-052', NULL, 'FT0001', '0056', '2022-05-23 07:35:01', NULL, 1, NULL, NULL, 0, NULL, NULL, NULL, NULL, 'TR150-00', 'QCL-DFB'),
	('XYS21999-072', NULL, 'FT0001', '0056', '2022-05-23 07:34:54', NULL, 1, NULL, NULL, 0, NULL, NULL, NULL, NULL, 'TR150-00', 'QCL-DFB'),
	('XYS21999-075', NULL, 'FT0001', '0056', '2022-05-23 07:34:58', NULL, 1, NULL, NULL, 0, NULL, NULL, NULL, NULL, 'TR150-00', 'QCL-DFB');

/*!40103 SET TIME_ZONE=IFNULL(@OLD_TIME_ZONE, 'system') */;
/*!40101 SET SQL_MODE=IFNULL(@OLD_SQL_MODE, '') */;
/*!40014 SET FOREIGN_KEY_CHECKS=IFNULL(@OLD_FOREIGN_KEY_CHECKS, 1) */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40111 SET SQL_NOTES=IFNULL(@OLD_SQL_NOTES, 1) */;
