-- MySQL dump 10.13  Distrib 8.0.36, for Win64 (x86_64)
--
-- Host: 192.168.201.207    Database: pozorisp_Marupov
-- ------------------------------------------------------
-- Server version	5.7.44

/*!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 `edenica`
--

DROP TABLE IF EXISTS `edenica`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `edenica` (
  `edenica` int(11) NOT NULL AUTO_INCREMENT,
  `edenica_name` varchar(45) COLLATE utf8mb4_unicode_ci NOT NULL,
  PRIMARY KEY (`edenica`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `edenica`
--

LOCK TABLES `edenica` WRITE;
/*!40000 ALTER TABLE `edenica` DISABLE KEYS */;
INSERT INTO `edenica` VALUES (1,'кг'),(2,'л');
/*!40000 ALTER TABLE `edenica` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `inn_type`
--

DROP TABLE IF EXISTS `inn_type`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `inn_type` (
  `idinn_type` int(11) NOT NULL AUTO_INCREMENT,
  `inn_name` varchar(45) COLLATE utf8mb4_unicode_ci NOT NULL,
  PRIMARY KEY (`idinn_type`)
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `inn_type`
--

LOCK TABLES `inn_type` WRITE;
/*!40000 ALTER TABLE `inn_type` DISABLE KEYS */;
INSERT INTO `inn_type` VALUES (1,'ЗАО'),(2,'ООО'),(3,'ПАО'),(4,'ОАО');
/*!40000 ALTER TABLE `inn_type` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `material`
--

DROP TABLE IF EXISTS `material`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `material` (
  `idmaterial` int(11) NOT NULL AUTO_INCREMENT,
  `material_name` varchar(45) COLLATE utf8mb4_unicode_ci NOT NULL,
  `material_typeid` int(11) NOT NULL,
  `unit_price` decimal(10,2) NOT NULL,
  `amount` decimal(10,2) NOT NULL,
  `amount_min` decimal(10,2) NOT NULL,
  `amount_in_unit` int(11) NOT NULL,
  `edenicaid` int(11) NOT NULL,
  PRIMARY KEY (`idmaterial`),
  KEY `fk_material_edenica_idx` (`edenicaid`),
  KEY `fk_material_materialtype_idx` (`material_typeid`),
  CONSTRAINT `fk_material_edenica` FOREIGN KEY (`edenicaid`) REFERENCES `edenica` (`edenica`) ON DELETE NO ACTION ON UPDATE NO ACTION,
  CONSTRAINT `fk_material_materialtype` FOREIGN KEY (`material_typeid`) REFERENCES `material_type` (`idmaterial_type`) ON DELETE NO ACTION ON UPDATE NO ACTION
) ENGINE=InnoDB AUTO_INCREMENT=21 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `material`
--

LOCK TABLES `material` WRITE;
/*!40000 ALTER TABLE `material` DISABLE KEYS */;
INSERT INTO `material` VALUES (1,'Глина',1,15.29,1570.00,5500.00,30,1),(2,'Каолин',1,18.20,1030.00,3500.00,25,1),(3,'Гидрослюда',1,17.20,2147.00,3500.00,25,1),(4,'Монтмориллонит',1,17.67,3000.00,3000.00,30,1),(5,'Перлит',1,13.99,150.00,1000.00,50,2),(6,'Стекло',1,2.40,3000.00,1500.00,500,1),(7,'Дегидратированная глина',1,21.95,3000.00,2500.00,20,1),(8,'Шамот',1,27.50,2300.00,1960.00,20,1),(9,'Техническая сода',3,54.55,1200.00,1500.00,25,1),(10,'Жидкое стекло',3,76.59,500.00,1500.00,15,1),(11,'Кварц',4,375.96,1500.00,2500.00,10,1),(12,'Полевой шпат',4,15.99,750.00,1500.00,100,1),(13,'Краска-раствор',5,200.90,1496.00,2500.00,5,2),(14,'Порошок цветной',5,84.39,511.00,1750.00,25,1),(15,'Кварцевый песок',1,4.29,3000.00,1600.00,50,1),(16,'Жильный кварц',1,18.60,2556.00,1600.00,25,1),(17,'Барий углекислый',4,303.64,340.00,1500.00,25,1),(18,'Бура техническая',4,125.99,165.00,1300.00,25,1),(19,'Углещелочной реагент',3,3.45,450.00,1100.00,25,1),(20,'Пирофосфат натрия',3,700.99,356.00,1200.00,25,1);
/*!40000 ALTER TABLE `material` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `material_supplier`
--

DROP TABLE IF EXISTS `material_supplier`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `material_supplier` (
  `idmaterial_supplier` int(11) NOT NULL AUTO_INCREMENT,
  `materialid` int(11) NOT NULL,
  `supplierid` int(11) NOT NULL,
  PRIMARY KEY (`idmaterial_supplier`),
  KEY `fk_matsup_material_idx` (`materialid`),
  KEY `fk_matsup_supplier_idx` (`supplierid`),
  CONSTRAINT `fk_ms_material` FOREIGN KEY (`materialid`) REFERENCES `material` (`idmaterial`) ON DELETE NO ACTION ON UPDATE NO ACTION,
  CONSTRAINT `fk_ms_supplier` FOREIGN KEY (`supplierid`) REFERENCES `suppliers` (`idsuppliers`) ON DELETE NO ACTION ON UPDATE NO ACTION
) ENGINE=InnoDB AUTO_INCREMENT=81 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `material_supplier`
--

LOCK TABLES `material_supplier` WRITE;
/*!40000 ALTER TABLE `material_supplier` DISABLE KEYS */;
INSERT INTO `material_supplier` VALUES (1,13,19),(2,2,3),(3,2,9),(4,6,19),(5,15,1),(6,5,6),(7,1,4),(8,15,20),(9,7,9),(10,12,4),(11,1,1),(12,14,19),(13,16,17),(14,12,1),(15,3,9),(16,6,20),(17,12,12),(18,4,9),(19,11,11),(20,17,17),(21,10,12),(22,8,17),(23,1,6),(24,11,15),(25,3,3),(26,5,9),(27,8,19),(28,17,20),(29,18,20),(30,9,18),(31,20,20),(32,3,4),(33,16,15),(34,5,10),(35,15,15),(36,4,4),(37,13,12),(38,6,7),(39,14,12),(40,2,1),(41,10,18),(42,18,7),(43,7,11),(44,18,13),(45,4,3),(46,10,16),(47,10,7),(48,14,16),(49,14,8),(50,19,16),(51,11,14),(52,16,13),(53,13,16),(54,11,13),(55,7,2),(56,15,14),(57,17,7),(58,8,2),(59,7,7),(60,3,5),(61,20,7),(62,5,5),(63,9,7),(64,1,10),(65,9,16),(66,4,10),(67,19,12),(68,9,8),(69,18,2),(70,20,5),(71,16,10),(72,6,2),(73,19,8),(74,17,5),(75,20,8),(76,2,5),(77,8,11),(78,19,5),(79,13,8),(80,12,10);
/*!40000 ALTER TABLE `material_supplier` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `material_type`
--

DROP TABLE IF EXISTS `material_type`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `material_type` (
  `idmaterial_type` int(11) NOT NULL AUTO_INCREMENT,
  `type_name` varchar(45) COLLATE utf8mb4_unicode_ci NOT NULL,
  `percent` varchar(45) COLLATE utf8mb4_unicode_ci NOT NULL,
  PRIMARY KEY (`idmaterial_type`)
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `material_type`
--

LOCK TABLES `material_type` WRITE;
/*!40000 ALTER TABLE `material_type` DISABLE KEYS */;
INSERT INTO `material_type` VALUES (1,'Пластичные материалы','0,12%'),(2,'Добавка','0,20%'),(3,'Электролит','0,15%'),(4,'Глазурь','0,30%'),(5,'Пигмент','0,25%');
/*!40000 ALTER TABLE `material_type` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `product_type`
--

DROP TABLE IF EXISTS `product_type`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `product_type` (
  `idproduct_type` int(11) NOT NULL AUTO_INCREMENT,
  `producttype_name` varchar(45) COLLATE utf8mb4_unicode_ci NOT NULL,
  `coef` decimal(10,2) NOT NULL,
  PRIMARY KEY (`idproduct_type`)
) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `product_type`
--

LOCK TABLES `product_type` WRITE;
/*!40000 ALTER TABLE `product_type` DISABLE KEYS */;
INSERT INTO `product_type` VALUES (1,'Тип продукции 1',1.20),(2,'Тип продукции 2',8.59),(3,'Тип продукции 3',3.45),(4,'Тип продукции 4',5.60);
/*!40000 ALTER TABLE `product_type` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `suppliers`
--

DROP TABLE IF EXISTS `suppliers`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `suppliers` (
  `idsuppliers` int(11) NOT NULL AUTO_INCREMENT,
  `supplier_name` varchar(45) COLLATE utf8mb4_unicode_ci NOT NULL,
  `inn_typeid` int(11) NOT NULL,
  `inn` bigint(12) NOT NULL,
  `rating` varchar(45) COLLATE utf8mb4_unicode_ci NOT NULL,
  `start_worktime` datetime NOT NULL,
  PRIMARY KEY (`idsuppliers`),
  UNIQUE KEY `inn_UNIQUE` (`inn`),
  KEY `fk_suppliers_inntype_idx` (`inn_typeid`),
  CONSTRAINT `fk_suppliers_inntype` FOREIGN KEY (`inn_typeid`) REFERENCES `inn_type` (`idinn_type`) ON DELETE NO ACTION ON UPDATE NO ACTION
) ENGINE=InnoDB AUTO_INCREMENT=21 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `suppliers`
--

LOCK TABLES `suppliers` WRITE;
/*!40000 ALTER TABLE `suppliers` DISABLE KEYS */;
INSERT INTO `suppliers` VALUES (1,'БрянскСтройресурс',1,9432455179,'8','2020-12-20 15:00:00'),(2,'Стройкомплект',1,7803888520,'7','2013-09-20 17:00:00'),(3,'Железногорская руда',2,8430391035,'7','2023-12-20 16:00:00'),(4,'Белая гора',2,4318170454,'8','2027-05-20 19:00:00'),(5,'Тульский обрабатывающий завод ',2,7687851800,'7','2016-06-20 15:00:00'),(6,'ГорТехРазработка',3,6119144874,'9','2027-12-20 21:00:00'),(7,'Сапфир',4,1122170258,'3','2010-04-20 22:00:00'),(8,'ХимБытСервис',3,8355114917,'5','2013-03-20 22:00:00'),(9,'ВоронежРудоКомбинат',4,3532367439,'8','2011-11-20 23:00:00'),(10,'Смоленский добывающий комбинат',4,2362431140,'3','2023-11-20 18:00:00'),(11,'МосКарьер',3,4159215346,'2','2007-07-20 12:00:00'),(12,'КурскРесурс',1,9032455179,'4','2023-07-20 21:00:00'),(13,'Нижегородская разработка',4,3776671267,'9','2023-05-20 16:00:00'),(14,'Речная долина',4,7447864518,'8','2025-06-20 15:00:00'),(15,'Карелия добыча',3,9037040523,'6','2009-03-20 17:00:00'),(16,'Московский ХимЗавод',3,6221520857,'4','2007-05-20 15:00:00'),(17,'Горная компания',1,2262431140,'3','2022-12-20 20:00:00'),(18,'Минерал Ресурс',2,4155215346,'7','2022-05-20 15:00:00'),(19,'Арсенал',1,3961234561,'5','2025-11-20 10:00:00'),(20,'КамчаткаСтройМинералы',1,9600275878,'7','2020-12-20 16:00:00');
/*!40000 ALTER TABLE `suppliers` ENABLE KEYS */;
UNLOCK TABLES;
/*!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 2026-05-15 11:26:33
