You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

727 lines
30 KiB

-- MySQL dump 10.13 Distrib 8.0.40, for Win64 (x86_64)
--
-- Host: localhost Database: car_sale
-- ------------------------------------------------------
-- Server version 8.0.40
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!50503 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!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 */;
--
-- Table structure for table `applyer`
--
DROP TABLE IF EXISTS `applyer`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `applyer` (
`idapplyer` int NOT NULL AUTO_INCREMENT,
`applyName` varchar(45) NOT NULL,
`applyEmail` varchar(45) NOT NULL,
`applyAddress` varchar(45) NOT NULL,
PRIMARY KEY (`idapplyer`),
KEY `applyName` (`applyName`(10)) /*!80000 INVISIBLE */,
KEY `applyAddress` (`applyAddress`(10))
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `applyer`
--
LOCK TABLES `applyer` WRITE;
/*!40000 ALTER TABLE `applyer` DISABLE KEYS */;
INSERT INTO `applyer` VALUES (1,'阳光汽配','138888','北京市东城区'),(2,'宏远汽配','139999','上海市黄浦区'),(3,'瑞丰汽配','156666','广州荔湾区'),(4,'通达汽配','135555','济南历下区'),(5,'星辰汽配','165555','天津河东区'),(6,'荣耀汽配','178888','成都市锦江区'),(7,'永盛汽配','157777','杭州市上城区'),(8,'新辉汽配','129999','福州市鼓楼区'),(9,'卓越汽配','152222','武汉市洪山区'),(10,'辉腾汽配','132222','深圳福田区');
/*!40000 ALTER TABLE `applyer` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Temporary view structure for view `applyer_view`
--
DROP TABLE IF EXISTS `applyer_view`;
/*!50001 DROP VIEW IF EXISTS `applyer_view`*/;
SET @saved_cs_client = @@character_set_client;
/*!50503 SET character_set_client = utf8mb4 */;
/*!50001 CREATE VIEW `applyer_view` AS SELECT
1 AS `供应商编号`,
1 AS `供应商名称`,
1 AS `联系方式`,
1 AS `联系地址`*/;
SET character_set_client = @saved_cs_client;
--
-- Table structure for table `cars`
--
DROP TABLE IF EXISTS `cars`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `cars` (
`idCars` int NOT NULL,
`shapeCars` varchar(45) NOT NULL,
`productionShape` varchar(45) NOT NULL,
`carPrice` varchar(45) NOT NULL,
PRIMARY KEY (`idCars`),
KEY `shapeCars` (`shapeCars`(10)) /*!80000 INVISIBLE */,
KEY `productionShape` (`productionShape`(10))
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `cars`
--
LOCK TABLES `cars` WRITE;
/*!40000 ALTER TABLE `cars` DISABLE KEYS */;
INSERT INTO `cars` VALUES (101,'BW','x3','30000'),(102,'BW','X3','200000'),(103,'BW','X5','150000'),(104,'MB','C','300000'),(105,'BW','S','250000'),(106,'MB','E','100000'),(107,'Ty','Cor','190000'),(108,'Ty','Cor','190000'),(109,'BYD','QIN','210000'),(110,'BYD','HAN','230000');
/*!40000 ALTER TABLE `cars` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Temporary view structure for view `cars_view`
--
DROP TABLE IF EXISTS `cars_view`;
/*!50001 DROP VIEW IF EXISTS `cars_view`*/;
SET @saved_cs_client = @@character_set_client;
/*!50503 SET character_set_client = utf8mb4 */;
/*!50001 CREATE VIEW `cars_view` AS SELECT
1 AS `汽车编号`,
1 AS `汽车品牌`,
1 AS `出厂类型`,
1 AS `售价`*/;
SET character_set_client = @saved_cs_client;
--
-- Table structure for table `customer`
--
DROP TABLE IF EXISTS `customer`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `customer` (
`idcustomer` int NOT NULL AUTO_INCREMENT,
`customerAddress` varchar(45) NOT NULL,
`customerEmail` varchar(45) NOT NULL,
`customerName` varchar(45) NOT NULL,
PRIMARY KEY (`idcustomer`),
KEY `customerAddress` (`customerAddress`(10)) /*!80000 INVISIBLE */,
KEY `customerEmail` (`customerEmail`(10)),
KEY `customerName` (`customerName`(10))
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `customer`
--
LOCK TABLES `customer` WRITE;
/*!40000 ALTER TABLE `customer` DISABLE KEYS */;
INSERT INTO `customer` VALUES (1,'北京朝阳区','133101','张三'),(2,'北京东城区','155183','李四'),(3,'上海浦东区','123211','赵甜'),(4,'上海徐汇区','134563','王五'),(5,'青岛黄岛区','167232','杨红'),(6,'重庆市南岸区','156723','陈一'),(7,'上海浦东区','112345','赵六'),(8,'杭州余杭区','145632','孙钱'),(9,'广东佛山','134524','李李'),(10,'北京朝阳区','145632','张璐');
/*!40000 ALTER TABLE `customer` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Temporary view structure for view `customer_view`
--
DROP TABLE IF EXISTS `customer_view`;
/*!50001 DROP VIEW IF EXISTS `customer_view`*/;
SET @saved_cs_client = @@character_set_client;
/*!50503 SET character_set_client = utf8mb4 */;
/*!50001 CREATE VIEW `customer_view` AS SELECT
1 AS `顾客id`,
1 AS `顾客地址`,
1 AS `顾客联系方式`,
1 AS `顾客姓名`*/;
SET character_set_client = @saved_cs_client;
--
-- Table structure for table `financestaff`
--
DROP TABLE IF EXISTS `financestaff`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `financestaff` (
`idFinanceStaff` int NOT NULL AUTO_INCREMENT,
`staffName` varchar(45) NOT NULL,
PRIMARY KEY (`idFinanceStaff`),
KEY `staffName` (`staffName`(10))
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `financestaff`
--
LOCK TABLES `financestaff` WRITE;
/*!40000 ALTER TABLE `financestaff` DISABLE KEYS */;
INSERT INTO `financestaff` VALUES (1,'小红'),(2,'小明'),(3,'小蓝'),(4,'小黄'),(5,'小粉'),(6,'小绿'),(7,'小黑'),(8,'小牛'),(9,'小朱'),(10,'小白');
/*!40000 ALTER TABLE `financestaff` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `fixstaff`
--
DROP TABLE IF EXISTS `fixstaff`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `fixstaff` (
`idfixstaff` int NOT NULL AUTO_INCREMENT,
`staffName` varchar(45) NOT NULL,
PRIMARY KEY (`idfixstaff`),
KEY `staffName` (`staffName`(10))
) ENGINE=InnoDB AUTO_INCREMENT=21 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `fixstaff`
--
LOCK TABLES `fixstaff` WRITE;
/*!40000 ALTER TABLE `fixstaff` DISABLE KEYS */;
INSERT INTO `fixstaff` VALUES (12,'大红'),(13,'王三'),(14,'大黑'),(15,'大绿'),(16,'大蓝'),(18,'大粉'),(19,'大青'),(20,'大棕');
/*!40000 ALTER TABLE `fixstaff` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `insurance`
--
DROP TABLE IF EXISTS `insurance`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `insurance` (
`idinsurance` int NOT NULL AUTO_INCREMENT,
`idCars` varchar(45) NOT NULL,
`dataInsurance` varchar(45) NOT NULL,
`insuranceStatus` varchar(45) NOT NULL,
PRIMARY KEY (`idinsurance`),
KEY `dateInsurance` (`dataInsurance`(10)),
KEY `insuranceStatus` (`insuranceStatus`(10))
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `insurance`
--
LOCK TABLES `insurance` WRITE;
/*!40000 ALTER TABLE `insurance` DISABLE KEYS */;
INSERT INTO `insurance` VALUES (1,'0101','20351230','平安人寿'),(2,'0102','20500920','平安'),(3,'0103','20400302','新华'),(4,'0104','20250721','太平洋'),(5,'0105','20250901','泰康'),(6,'0106','20260802','人保'),(7,'0107','20270501','大地'),(8,'0108','20270901','阳光'),(9,'0109','20280702','中华联保'),(10,'0110','20280405','中国人寿');
/*!40000 ALTER TABLE `insurance` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Temporary view structure for view `insurance_view`
--
DROP TABLE IF EXISTS `insurance_view`;
/*!50001 DROP VIEW IF EXISTS `insurance_view`*/;
SET @saved_cs_client = @@character_set_client;
/*!50503 SET character_set_client = utf8mb4 */;
/*!50001 CREATE VIEW `insurance_view` AS SELECT
1 AS `保险编号`,
1 AS `车辆编号`,
1 AS `保险到期时间`,
1 AS `保险类型`*/;
SET character_set_client = @saved_cs_client;
--
-- Table structure for table `lapply`
--
DROP TABLE IF EXISTS `lapply`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `lapply` (
`idCars` int NOT NULL,
`idapplyer` int NOT NULL,
`idparts` int NOT NULL,
`lapplydate` varchar(45) DEFAULT NULL,
PRIMARY KEY (`idCars`,`idapplyer`,`idparts`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `lapply`
--
LOCK TABLES `lapply` WRITE;
/*!40000 ALTER TABLE `lapply` DISABLE KEYS */;
INSERT INTO `lapply` VALUES (101,1,1,'2024-1-1'),(101,2,3,'2024-1-1'),(102,1,3,'2024-5-1'),(102,3,6,'2024-5-1'),(103,4,7,'2024-3-1'),(103,6,3,'2024-3-1'),(104,4,5,'2024-6-1'),(104,8,2,'2024-6-1'),(105,4,10,'2024-9-1'),(105,9,4,'2024-9-1'),(106,5,3,'2024-9-3'),(106,7,4,'2024-9-3'),(107,4,6,'2024-8-18'),(107,5,1,'2024-8-18'),(108,4,2,'2024-4-21'),(108,8,2,'2024-4-21'),(109,2,7,'2024-5-6'),(109,9,10,'2024-5-6'),(110,2,6,'2024-7-21'),(110,10,10,'2024-7-21');
/*!40000 ALTER TABLE `lapply` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `lbuy`
--
DROP TABLE IF EXISTS `lbuy`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `lbuy` (
`idsaleOrder` int NOT NULL,
`idcustomer` int NOT NULL,
`idCars` int NOT NULL,
`buydate` varchar(45) NOT NULL,
PRIMARY KEY (`idsaleOrder`,`idcustomer`,`idCars`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `lbuy`
--
LOCK TABLES `lbuy` WRITE;
/*!40000 ALTER TABLE `lbuy` DISABLE KEYS */;
INSERT INTO `lbuy` VALUES (1,1,101,'2024-01-05'),(2,2,102,'2024-02-02'),(3,3,103,'2024-04-09'),(4,4,104,'2024-05-15'),(5,5,105,'2024-06-03'),(6,6,106,'2024-07-10'),(7,9,107,'2024-09-18'),(8,8,108,'2024-09-12'),(9,9,109,'2024-09-25'),(10,10,110,'2024-10-30');
/*!40000 ALTER TABLE `lbuy` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `lcihave1`
--
DROP TABLE IF EXISTS `lcihave1`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `lcihave1` (
`idinsurance` int NOT NULL AUTO_INCREMENT,
`idCars` varchar(45) NOT NULL,
PRIMARY KEY (`idinsurance`,`idCars`)
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `lcihave1`
--
LOCK TABLES `lcihave1` WRITE;
/*!40000 ALTER TABLE `lcihave1` DISABLE KEYS */;
INSERT INTO `lcihave1` VALUES (1,'101'),(2,'103'),(3,'105'),(4,'102'),(5,'107'),(6,'108'),(7,'109'),(8,'110'),(9,'104'),(10,'106');
/*!40000 ALTER TABLE `lcihave1` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `lcphave2`
--
DROP TABLE IF EXISTS `lcphave2`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `lcphave2` (
`idCars` int NOT NULL,
`idparts` int NOT NULL,
PRIMARY KEY (`idCars`,`idparts`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `lcphave2`
--
LOCK TABLES `lcphave2` WRITE;
/*!40000 ALTER TABLE `lcphave2` DISABLE KEYS */;
INSERT INTO `lcphave2` VALUES (101,1),(101,2),(101,3),(102,1),(102,2),(102,6),(102,7),(103,1),(103,2),(103,4),(104,1),(104,2),(104,5),(104,6),(104,7),(105,1),(105,2),(105,5),(105,6),(105,7),(105,8),(106,1),(106,2),(106,5),(107,1),(107,2),(107,8),(107,9),(108,1),(108,2),(108,7),(109,1),(109,2),(109,4),(109,7),(110,1),(110,2),(110,6),(110,7);
/*!40000 ALTER TABLE `lcphave2` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `lfix`
--
DROP TABLE IF EXISTS `lfix`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `lfix` (
`idfixstaff` int NOT NULL,
`idparts` int NOT NULL,
PRIMARY KEY (`idfixstaff`,`idparts`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `lfix`
--
LOCK TABLES `lfix` WRITE;
/*!40000 ALTER TABLE `lfix` DISABLE KEYS */;
INSERT INTO `lfix` VALUES (11,1),(12,2),(13,3),(14,4),(15,5),(16,6),(17,7),(18,8),(19,9),(20,10);
/*!40000 ALTER TABLE `lfix` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `lquery`
--
DROP TABLE IF EXISTS `lquery`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `lquery` (
`idFinanceSalestaff` int NOT NULL,
`idsaleorder` int NOT NULL,
`querydate` varchar(45) NOT NULL,
PRIMARY KEY (`idFinanceSalestaff`,`idsaleorder`),
KEY `fk-idsaleOrder_idx` (`idsaleorder`),
CONSTRAINT `fk-idFinanceStaff` FOREIGN KEY (`idFinanceSalestaff`) REFERENCES `financestaff` (`idFinanceStaff`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `lquery`
--
LOCK TABLES `lquery` WRITE;
/*!40000 ALTER TABLE `lquery` DISABLE KEYS */;
INSERT INTO `lquery` VALUES (1,1,'2024-01-05'),(2,2,'2024-02-02'),(3,3,'2024-04-09'),(4,4,'2024-05-15'),(5,5,'2024-06-03'),(6,6,'2024-07-10'),(7,7,'2024-08-18'),(8,8,'2024-09-12'),(9,9,'2024-09-25'),(10,10,'2024-10-30');
/*!40000 ALTER TABLE `lquery` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Temporary view structure for view `lquery_view`
--
DROP TABLE IF EXISTS `lquery_view`;
/*!50001 DROP VIEW IF EXISTS `lquery_view`*/;
SET @saved_cs_client = @@character_set_client;
/*!50503 SET character_set_client = utf8mb4 */;
/*!50001 CREATE VIEW `lquery_view` AS SELECT
1 AS `财政人员编号`,
1 AS `销售订单编号`,
1 AS `查询日期`*/;
SET character_set_client = @saved_cs_client;
--
-- Table structure for table `lrecord`
--
DROP TABLE IF EXISTS `lrecord`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `lrecord` (
`idsaleorder` int NOT NULL,
`idsalestaff` int NOT NULL,
`recorddate` varchar(45) NOT NULL,
PRIMARY KEY (`idsaleorder`,`idsalestaff`),
KEY `fk-idsalestaff_idx` (`idsalestaff`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `lrecord`
--
LOCK TABLES `lrecord` WRITE;
/*!40000 ALTER TABLE `lrecord` DISABLE KEYS */;
INSERT INTO `lrecord` VALUES (1,21,'2024-01-06'),(2,22,'2024-02-03'),(3,23,'2024-04-10'),(4,24,'2024-05-16'),(5,25,'2024-06-04'),(6,26,'2024-07-11'),(7,27,'2024-08-19'),(8,28,'2024-09-13'),(9,29,'2024-09-26'),(10,30,'2024-10-31');
/*!40000 ALTER TABLE `lrecord` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Temporary view structure for view `lrecord_view`
--
DROP TABLE IF EXISTS `lrecord_view`;
/*!50001 DROP VIEW IF EXISTS `lrecord_view`*/;
SET @saved_cs_client = @@character_set_client;
/*!50503 SET character_set_client = utf8mb4 */;
/*!50001 CREATE VIEW `lrecord_view` AS SELECT
1 AS `销售订单编号`,
1 AS `销售人员编号`,
1 AS `记录日期`*/;
SET character_set_client = @saved_cs_client;
--
-- Table structure for table `lsale`
--
DROP TABLE IF EXISTS `lsale`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `lsale` (
`idcustomer` int NOT NULL,
`idsalestaff` int NOT NULL,
`idCars` int NOT NULL,
`saledate` date NOT NULL,
PRIMARY KEY (`idcustomer`,`idsalestaff`,`idCars`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `lsale`
--
LOCK TABLES `lsale` WRITE;
/*!40000 ALTER TABLE `lsale` DISABLE KEYS */;
INSERT INTO `lsale` VALUES (1,21,101,'2024-01-05'),(2,22,102,'2024-02-02'),(3,23,103,'2024-04-09'),(4,24,104,'2024-05-15'),(5,25,105,'2024-06-03'),(6,26,106,'2024-07-10'),(7,27,107,'2024-08-18'),(8,28,108,'2024-09-12'),(9,29,109,'2024-09-25'),(10,30,110,'2024-10-30');
/*!40000 ALTER TABLE `lsale` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `parts`
--
DROP TABLE IF EXISTS `parts`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `parts` (
`idparts` int NOT NULL AUTO_INCREMENT,
`price` int NOT NULL,
`partName` varchar(45) NOT NULL,
`partsNumber` int NOT NULL,
PRIMARY KEY (`idparts`),
KEY `partsName` (`partName`(10)) /*!80000 INVISIBLE */
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `parts`
--
LOCK TABLES `parts` WRITE;
/*!40000 ALTER TABLE `parts` DISABLE KEYS */;
INSERT INTO `parts` VALUES (1,25000,'发动机总成',5),(2,800,'汽车轮胎',20),(3,350,'刹车盘',15),(4,80,'火花塞',30),(5,50,'空气滤清器',40),(6,60,'燃油滤清器',35),(7,1200,'前保险杠',8),(8,800,'后保险杠',10),(9,450,'车门内饰板',6),(10,1500,'汽车大灯',12);
/*!40000 ALTER TABLE `parts` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `saleorder`
--
DROP TABLE IF EXISTS `saleorder`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `saleorder` (
`idsaleOrder` int NOT NULL AUTO_INCREMENT,
`idCars` int NOT NULL,
`idcustomer` varchar(45) NOT NULL,
`dateOrder` date NOT NULL,
`statusOrder` varchar(45) NOT NULL,
PRIMARY KEY (`idsaleOrder`)
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `saleorder`
--
LOCK TABLES `saleorder` WRITE;
/*!40000 ALTER TABLE `saleorder` DISABLE KEYS */;
INSERT INTO `saleorder` VALUES (1,101,'1','2024-01-05','已下单'),(2,102,'2','2024-02-02','已发货'),(3,103,'3','2024-04-09','待付款'),(4,104,'4','2024-05-15','已交付'),(5,105,'5','2024-06-03','已取消'),(6,106,'6','2024-07-10','运输中'),(7,107,'7','2024-08-18','已下单'),(8,108,'8','2024-09-12','已发货'),(9,109,'9','2024-09-25','待付款'),(10,110,'10','2024-10-30','已交付');
/*!40000 ALTER TABLE `saleorder` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Temporary view structure for view `saleorder_view`
--
DROP TABLE IF EXISTS `saleorder_view`;
/*!50001 DROP VIEW IF EXISTS `saleorder_view`*/;
SET @saved_cs_client = @@character_set_client;
/*!50503 SET character_set_client = utf8mb4 */;
/*!50001 CREATE VIEW `saleorder_view` AS SELECT
1 AS `销售订单编号`,
1 AS `车辆编号`,
1 AS `顾客编号`,
1 AS `订单日期`,
1 AS `订单状态`*/;
SET character_set_client = @saved_cs_client;
--
-- Table structure for table `salestaff`
--
DROP TABLE IF EXISTS `salestaff`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `salestaff` (
`idsalestaff` int NOT NULL AUTO_INCREMENT,
`staffName` varchar(45) NOT NULL,
PRIMARY KEY (`idsalestaff`),
KEY `staffName` (`staffName`(10))
) ENGINE=InnoDB AUTO_INCREMENT=31 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `salestaff`
--
LOCK TABLES `salestaff` WRITE;
/*!40000 ALTER TABLE `salestaff` DISABLE KEYS */;
INSERT INTO `salestaff` VALUES (21,'李华'),(22,'王强'),(23,'张明'),(24,'刘阳'),(25,'陈杰'),(26,'赵琳'),(27,'孙悦'),(28,'周涛'),(29,'吴斌'),(30,'郑浩');
/*!40000 ALTER TABLE `salestaff` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `staff`
--
DROP TABLE IF EXISTS `staff`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `staff` (
`idstaff` int NOT NULL AUTO_INCREMENT,
`staffName` varchar(45) NOT NULL,
PRIMARY KEY (`idstaff`)
) ENGINE=InnoDB AUTO_INCREMENT=104 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `staff`
--
LOCK TABLES `staff` WRITE;
/*!40000 ALTER TABLE `staff` DISABLE KEYS */;
INSERT INTO `staff` VALUES (101,'财政人员'),(102,'销售人员'),(103,'维修人员');
/*!40000 ALTER TABLE `staff` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Final view structure for view `applyer_view`
--
/*!50001 DROP VIEW IF EXISTS `applyer_view`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = utf8mb4 */;
/*!50001 SET character_set_results = utf8mb4 */;
/*!50001 SET collation_connection = utf8mb4_0900_ai_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `applyer_view` AS select `applyer`.`idapplyer` AS `供应商编号`,`applyer`.`applyName` AS `供应商名称`,`applyer`.`applyEmail` AS `联系方式`,`applyer`.`applyAddress` AS `联系地址` from `applyer` where (`applyer`.`applyAddress` = '北京市东城区') */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `cars_view`
--
/*!50001 DROP VIEW IF EXISTS `cars_view`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = utf8mb4 */;
/*!50001 SET character_set_results = utf8mb4 */;
/*!50001 SET collation_connection = utf8mb4_0900_ai_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `cars_view` AS select `cars`.`idCars` AS `汽车编号`,`cars`.`shapeCars` AS `汽车品牌`,`cars`.`productionShape` AS `出厂类型`,`cars`.`carPrice` AS `售价` from `cars` where (`cars`.`carPrice` >= 200000) */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `customer_view`
--
/*!50001 DROP VIEW IF EXISTS `customer_view`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = utf8mb4 */;
/*!50001 SET character_set_results = utf8mb4 */;
/*!50001 SET collation_connection = utf8mb4_0900_ai_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `customer_view` AS select `customer`.`idcustomer` AS `顾客id`,`customer`.`customerAddress` AS `顾客地址`,`customer`.`customerEmail` AS `顾客联系方式`,`customer`.`customerName` AS `顾客姓名` from `customer` where (`customer`.`customerAddress` = '北京朝阳区') */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `insurance_view`
--
/*!50001 DROP VIEW IF EXISTS `insurance_view`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = utf8mb4 */;
/*!50001 SET character_set_results = utf8mb4 */;
/*!50001 SET collation_connection = utf8mb4_0900_ai_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `insurance_view` AS select `insurance`.`idinsurance` AS `保险编号`,`insurance`.`idCars` AS `车辆编号`,`insurance`.`dataInsurance` AS `保险到期时间`,`insurance`.`insuranceStatus` AS `保险类型` from `insurance` where (`insurance`.`idinsurance` > 5) */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `lquery_view`
--
/*!50001 DROP VIEW IF EXISTS `lquery_view`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = utf8mb4 */;
/*!50001 SET character_set_results = utf8mb4 */;
/*!50001 SET collation_connection = utf8mb4_0900_ai_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `lquery_view` AS select `lquery`.`idFinanceSalestaff` AS `财政人员编号`,`lquery`.`idsaleorder` AS `销售订单编号`,`lquery`.`querydate` AS `查询日期` from `lquery` where (cast(`lquery`.`querydate` as date) > '2024-05-15') */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `lrecord_view`
--
/*!50001 DROP VIEW IF EXISTS `lrecord_view`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = utf8mb4 */;
/*!50001 SET character_set_results = utf8mb4 */;
/*!50001 SET collation_connection = utf8mb4_0900_ai_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `lrecord_view` AS select `lrecord`.`idsaleorder` AS `销售订单编号`,`lrecord`.`idsalestaff` AS `销售人员编号`,`lrecord`.`recorddate` AS `记录日期` from `lrecord` where ((`lrecord`.`idsalestaff` > 22) and (`lrecord`.`recorddate` < '2024-09-21')) */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `saleorder_view`
--
/*!50001 DROP VIEW IF EXISTS `saleorder_view`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = utf8mb4 */;
/*!50001 SET character_set_results = utf8mb4 */;
/*!50001 SET collation_connection = utf8mb4_0900_ai_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `saleorder_view` AS select `saleorder`.`idsaleOrder` AS `销售订单编号`,`saleorder`.`idCars` AS `车辆编号`,`saleorder`.`idcustomer` AS `顾客编号`,`saleorder`.`dateOrder` AS `订单日期`,`saleorder`.`statusOrder` AS `订单状态` from `saleorder` where (((`saleorder`.`dateOrder` > '2024-04-09') and (`saleorder`.`statusOrder` = '已下单')) or (`saleorder`.`statusOrder` = '已交付')) */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-- Dump completed on 2024-12-27 20:36:21