text: -- phpMyAdmin SQL Dump
  -- version 5.0.3
  -- https://www.phpmyadmin.net/
  --
  -- Host: 127.0.0.1
  -- Generation Time: Mar 09, 2021 at 01:11 PM
  -- Server version: 10.4.14-MariaDB
  -- PHP Version: 7.2.34
  
  SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
  START TRANSACTION;
  SET time_zone = "+00:00";
  
  
  /*!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 */;
  /*!40101 SET NAMES utf8mb4 */;
  
  --
  -- Database: `db_toko`
  --
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `barang`
  --
  
  CREATE TABLE `barang` (
    `id` int(11) NOT NULL,
    `id_barang` varchar(255) NOT NULL,
    `id_kategori` int(11) NOT NULL,
    `nama_barang` text NOT NULL,
    `merk` varchar(255) NOT NULL,
    `harga_beli` varchar(255) NOT NULL,
    `harga_jual` varchar(255) NOT NULL,
    `satuan_barang` varchar(255) NOT NULL,
    `stok` text NOT NULL,
    `tgl_input` varchar(255) NOT NULL,
    `tgl_update` varchar(255) DEFAULT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
  
  --
  -- Dumping data for table `barang`
  --
  
  INSERT INTO `barang` (`id`, `id_barang`, `id_kategori`, `nama_barang`, `merk`, `harga_beli`, `harga_jual`, `satuan_barang`, `stok`, `tgl_input`, `tgl_update`) VALUES
  (1, 'BR001', 1, 'Pensil', 'Fabel Castel', '1500', '3000', 'PCS', '99', '6 October 2020, 0:41', NULL),
  (2, 'BR002', 5, 'Sabun', 'Lifeboy', '1800', '3000', 'PCS', '36', '6 October 2020, 0:41', '6 October 2020, 0:54'),
  (3, 'BR003', 1, 'Pulpen', 'Standard', '1500', '2000', 'PCS', '67', '6 October 2020, 1:34', NULL),
  (4, 'BR004', 5, 'Sabun colek', 'Dangdut', '1000', '2000', 'PCS', '98', '9 March 2021, 19:02', NULL);
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `kategori`
  --
  
  CREATE TABLE `kategori` (
    `id_kategori` int(11) NOT NULL,
    `nama_kategori` varchar(255) NOT NULL,
    `tgl_input` varchar(255) NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
  
  --
  -- Dumping data for table `kategori`
  --
  
  INSERT INTO `kategori` (`id_kategori`, `nama_kategori`, `tgl_input`) VALUES
  (1, 'ATK', '7 May 2017, 10:23'),
  (5, 'Sabun', '7 May 2017, 10:28'),
  (6, 'Snack', '6 October 2020, 0:19'),
  (7, 'Minuman', '6 October 2020, 0:20');
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `login`
  --
  
  CREATE TABLE `login` (
    `id_login` int(11) NOT NULL,
    `user` varchar(255) NOT NULL,
    `pass` char(32) NOT NULL,
    `id_member` int(11) NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
  
  --
  -- Dumping data for table `login`
  --
  
  INSERT INTO `login` (`id_login`, `user`, `pass`, `id_member`) VALUES
  (1, 'admin', '202cb962ac59075b964b07152d234b70', 1);
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `member`
  --
  
  CREATE TABLE `member` (
    `id_member` int(11) NOT NULL,
    `nm_member` varchar(255) NOT NULL,
    `alamat_member` text NOT NULL,
    `telepon` varchar(255) NOT NULL,
    `email` varchar(255) NOT NULL,
    `gambar` text NOT NULL,
    `NIK` text NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
  
  --
  -- Dumping data for table `member`
  --
  
  INSERT INTO `member` (`id_member`, `nm_member`, `alamat_member`, `telepon`, `email`, `gambar`, `NIK`) VALUES
  (1, 'erick irwansyah', 'Bengkulu', '085809933656', 'erickirwansyah5a@gmail.com', 'BukaBeasiswa_erick irwansyah_universitas dehasen_FOTO (1).jpg', '12314121');
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `nota`
  --
  
  CREATE TABLE `nota` (
    `id_nota` int(11) NOT NULL,
    `id_barang` varchar(255) NOT NULL,
    `id_member` int(11) NOT NULL,
    `jumlah` varchar(255) NOT NULL,
    `total` varchar(255) NOT NULL,
    `tanggal_input` varchar(255) NOT NULL,
    `periode` varchar(255) DEFAULT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
  
  --
  -- Dumping data for table `nota`
  --
  
  INSERT INTO `nota` (`id_nota`, `id_barang`, `id_member`, `jumlah`, `total`, `tanggal_input`, `periode`) VALUES
  (1, 'BR001', 1, '4', '12000', '6 October 2020, 0:45', '10-2020'),
  (2, 'BR001', 1, '4', '12000', '6 October 2020, 0:45', '10-2020'),
  (3, 'BR001', 1, '4', '12000', '6 October 2020, 0:45', '10-2020'),
  (4, 'BR001', 1, '4', '12000', '6 October 2020, 0:45', '10-2020'),
  (5, 'BR001', 1, '2', '6000', '6 October 2020, 0:49', '10-2020'),
  (6, 'BR001', 1, '2', '6000', '6 October 2020, 0:49', '10-2020'),
  (7, 'BR001', 1, '2', '6000', '6 October 2020, 1:15', '10-2020'),
  (8, 'BR002', 1, '2', '6000', '6 October 2020, 1:17', '10-2020'),
  (9, 'BR001', 1, '2', '6000', '6 October 2020, 1:20', '10-2020'),
  (10, 'BR001', 1, '2', '6000', '6 October 2020, 1:51', '03-2021'),
  (11, 'BR002', 1, '2', '6000', '9 March 2021, 19:00', '03-2021'),
  (12, 'BR004', 1, '2', '4000', '9 March 2021, 19:05', '03-2021'),
  (13, 'BR001', 1, '2', '6000', '9 March 2021, 19:05', '03-2021'),
  (14, 'BR003', 1, '3', '6000', '9 March 2021, 19:06', '03-2021');
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `penjualan`
  --
  
  CREATE TABLE `penjualan` (
    `id_penjualan` int(11) NOT NULL,
    `id_barang` varchar(255) NOT NULL,
    `id_member` int(11) NOT NULL,
    `jumlah` varchar(255) NOT NULL,
    `total` varchar(255) NOT NULL,
    `tanggal_input` varchar(255) NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
  
  --
  -- Dumping data for table `penjualan`
  --
  
  INSERT INTO `penjualan` (`id_penjualan`, `id_barang`, `id_member`, `jumlah`, `total`, `tanggal_input`) VALUES
  (25, 'BR004', 1, '2', '4000', '9 March 2021, 19:05'),
  (26, 'BR001', 1, '2', '6000', '9 March 2021, 19:05'),
  (27, 'BR003', 1, '3', '6000', '9 March 2021, 19:06');
  
  -- --------------------------------------------------------
  
  --
  -- Table structure for table `toko`
  --
  
  CREATE TABLE `toko` (
    `id_toko` int(11) NOT NULL,
    `nama_toko` varchar(255) NOT NULL,
    `alamat_toko` text NOT NULL,
    `tlp` varchar(255) NOT NULL,
    `nama_pemilik` varchar(255) NOT NULL
  ) ENGINE=InnoDB DEFAULT CHARSET=latin1;
  
  --
  -- Dumping data for table `toko`
  --
  
  INSERT INTO `toko` (`id_toko`, `nama_toko`, `alamat_toko`, `tlp`, `nama_pemilik`) VALUES
  (1, 'Warung Alex Bengkulu', 'Jl. Lintas Bengkulu-Tais, KM. 32, Desa Lubuk Sahung, Kec. Sukaraja, Kab. Seluma', '085809933656', 'Erick Irwansyah');
  
  --
  -- Indexes for dumped tables
  --
  
  --
  -- Indexes for table `barang`
  --
  ALTER TABLE `barang`
    ADD PRIMARY KEY (`id`);
  
  --
  -- Indexes for table `kategori`
  --
  ALTER TABLE `kategori`
    ADD PRIMARY KEY (`id_kategori`);
  
  --
  -- Indexes for table `login`
  --
  ALTER TABLE `login`
    ADD PRIMARY KEY (`id_login`);
  
  --
  -- Indexes for table `member`
  --
  ALTER TABLE `member`
    ADD PRIMARY KEY (`id_member`);
  
  --
  -- Indexes for table `nota`
  --
  ALTER TABLE `nota`
    ADD PRIMARY KEY (`id_nota`);
  
  --
  -- Indexes for table `penjualan`
  --
  ALTER TABLE `penjualan`
    ADD PRIMARY KEY (`id_penjualan`);
  
  --
  -- Indexes for table `toko`
  --
  ALTER TABLE `toko`
    ADD PRIMARY KEY (`id_toko`);
  
  --
  -- AUTO_INCREMENT for dumped tables
  --
  
  --
  -- AUTO_INCREMENT for table `barang`
  --
  ALTER TABLE `barang`
    MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=5;
  
  --
  -- AUTO_INCREMENT for table `kategori`
  --
  ALTER TABLE `kategori`
    MODIFY `id_kategori` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8;
  
  --
  -- AUTO_INCREMENT for table `login`
  --
  ALTER TABLE `login`
    MODIFY `id_login` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;
  
  --
  -- AUTO_INCREMENT for table `member`
  --
  ALTER TABLE `member`
    MODIFY `id_member` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;
  
  --
  -- AUTO_INCREMENT for table `nota`
  --
  ALTER TABLE `nota`
    MODIFY `id_nota` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=15;
  
  --
  -- AUTO_INCREMENT for table `penjualan`
  --
  ALTER TABLE `penjualan`
    MODIFY `id_penjualan` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=28;
  
  --
  -- AUTO_INCREMENT for table `toko`
  --
  ALTER TABLE `toko`
    MODIFY `id_toko` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=2;
  COMMIT;
  
  /*!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 */;
  