-- https://www.phpmyadmin.net/
--

START TRANSACTION;



-- --------------------------------------------------------

--
-- Table structure for table `FISA_achats`
--

CREATE TABLE `FISA_achats` (
  `idProd` int(11) NOT NULL,
  `idClient` int(11) NOT NULL,
  `nbAchats` int(11) NOT NULL,
  `dateAchats` date NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `FISA_achats`
--

INSERT INTO `FISA_achats` (`idProd`, `idClient`, `nbAchats`, `dateAchats`) VALUES
(230054, 2, 10, '2024-10-20'),
(654321, 2, 5, '2024-10-15'),
(230054, 1, 100, '2024-12-25'),
(654321, 3, 42, '2025-01-25'),
(123456, 1, 23, '2025-01-25');

-- --------------------------------------------------------

--
-- Table structure for table `FISA_clients`
--

CREATE TABLE `FISA_clients` (
  `idClient` int(11) NOT NULL,
  `nomClient` varchar(100) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `FISA_clients`
--

INSERT INTO `FISA_clients` (`idClient`, `nomClient`) VALUES
(1, 'Entreprise A'),
(2, 'Entreprise B'),
(3, 'Entreprise C');

-- --------------------------------------------------------

--
-- Table structure for table `FISA_prodFab`
--

CREATE TABLE `FISA_prodFab` (
  `idFab` int(11) NOT NULL,
  `idProd` int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `FISA_prodFab`
--

INSERT INTO `FISA_prodFab` (`idFab`, `idProd`) VALUES
(1, 230054),
(1, 654321),
(2, 123456),
(2, 502033);

-- --------------------------------------------------------

--
-- Table structure for table `FISA_produits`
--

CREATE TABLE `FISA_produits` (
  `idProd` int(11) NOT NULL,
  `nomProd` varchar(100) NOT NULL,
  `prixProd` float NOT NULL,
  `stockProd` int(11) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Dumping data for table `FISA_produits`
--

INSERT INTO `FISA_produits` (`idProd`, `nomProd`, `prixProd`, `stockProd`) VALUES
(123456, 'Lampe LED Smart Bluetooth 8W', 10.2, 256),
(230054, 'cable USB C 100W 480Mbps', 7.99, 20),
(502033, 'cable USB C charge rapide 60W', 6.98, 42),
(654321, 'Ruban LED 5m 25W', 21.99, 30);

-- --------------------------------------------------------

--
-- Indexes for dumped tables
--

--
-- Indexes for table `FISA_achats`
--
ALTER TABLE `FISA_achats`
  ADD KEY `idClient` (`idClient`);

--
-- Indexes for table `FISA_clients`
--
ALTER TABLE `FISA_clients`
  ADD PRIMARY KEY (`idClient`);

--
-- Indexes for table `FISA_prodFab`
--
ALTER TABLE `FISA_prodFab`
  ADD KEY `idFab` (`idFab`);

--
-- Indexes for table `FISA_produits`
--
ALTER TABLE `FISA_produits`
  ADD PRIMARY KEY (`idProd`);

--
-- AUTO_INCREMENT for dumped tables
--

--
-- AUTO_INCREMENT for table `FISA_clients`
--
ALTER TABLE `FISA_clients`
  MODIFY `idClient` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4;

--
