-- https://www.phpmyadmin.net/
--
-- Waktu pembuatan: 07 Bulan Mei 2026 pada 00.38
-- Versi server: 10.4.32-MariaDB
-- Versi PHP: 8.0.30

START TRANSACTION;



--
-- Database: `db_absensi_mts`
--

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

--
-- Struktur dari tabel `absensi`
--

CREATE TABLE `absensi` (
  `id` int(11) NOT NULL,
  `siswa_id` int(11) NOT NULL,
  `tanggal` date NOT NULL,
  `status` enum('Hadir','Izin','Sakit','Alpha') NOT NULL,
  `keterangan` text DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;

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

--
-- Struktur dari tabel `kelas`
--

CREATE TABLE `kelas` (
  `id` int(11) NOT NULL,
  `nama_kelas` varchar(50) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;

--
-- Dumping data untuk tabel `kelas`
--

INSERT INTO `kelas` (`id`, `nama_kelas`) VALUES
(1, '7 A'),
(2, '7 B'),
(3, '7 C'),
(4, '8 A'),
(5, '8 B'),
(6, '8 C'),
(7, '8 D');

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

--
-- Struktur dari tabel `siswa`
--

CREATE TABLE `siswa` (
  `id` int(11) NOT NULL,
  `nis` varchar(20) NOT NULL,
  `nama` varchar(100) NOT NULL,
  `kelas_id` int(11) NOT NULL,
  `no_hp_ortu` varchar(20) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;

--
-- Dumping data untuk tabel `siswa`
--

INSERT INTO `siswa` (`id`, `nis`, `nama`, `kelas_id`, `no_hp_ortu`) VALUES
(1, '1001', 'Ahmad Budi', 1, '081234567890'),
(2, '1002', 'Siti Aminah', 1, '089876543210'),
(3, '3123816404', 'ABI BANGUN PERKASA', 1, '081'),
(4, '0112400778', 'ANDIKA SUGIARTO', 1, '081'),
(5, '3136478586', 'MUHAMMAD FARID AKBAR ABIYANSYAH', 1, '081'),
(6, '3132605307', 'MUHAMMAD TEGAR PRASTYO', 1, '081'),
(7, '0131840897', 'RUDY ADITYA SAPUTRA', 1, '081'),
(8, '0129535845', 'FAZA AULIA AMANDA', 1, '081'),
(9, '0125125608', 'DIKA SAPUTRA', 1, '081'),
(10, '3130321113', 'AHMAD DICKY MAULANA', 1, '081'),
(11, '3121754634', 'AHMAD NURUNNIZAM', 1, '081'),
(12, '3125651162', 'ALI ARFAN ABDUL QADIR', 1, '081'),
(13, '3139286997', 'ALFIYAN ARDI PRASETYA', 1, '081'),
(14, '3117679484', 'M.RIZQI VARDIANSYAH', 1, '081'),
(15, '0122317139', 'SAFIRA ANGGRAINI', 1, '081'),
(16, '0137395976', 'KELFIN MAULANA', 1, '081'),
(17, '3133555623', 'NUR AZIZAH', 1, '081'),
(18, '3127469692', 'NAURA LUTFIA AZRA', 1, '081'),
(19, '3136930950', 'HAIDAR WAFI RAJIF HUSAIN', 1, '081'),
(20, '3139980391', 'IRMA WAHIDA MAIMUNAH', 1, '081'),
(21, '3128109290', 'KAMILA NAWWALIN NAJIHA', 1, '081'),
(22, '3136830427', 'NOVIANA PUTRI', 1, '081'),
(23, '3129404288', 'AHMAD DIMAS ARYA SAPUTRA', 1, '081'),
(24, '0128584263', 'MUHAMMAD RIZKI ANDIKA', 1, '081'),
(25, '0138642027', 'AHMAD AMMAR AL MUNAWAR', 1, '081'),
(26, '3130172151', 'NANA MUTIARA MUFLIHATUL AROFAH', 1, '081'),
(27, '3131846097', 'AHMAD KARIM DHARMAWAN', 1, '081'),
(28, '0128236654', 'PUTRA ANDIKA PRASTYIO', 1, '081'),
(29, '3121936528', 'ZARKASI MAULANA FARHAB', 1, '081'),
(30, '3135630834', 'BINTANG BRILIAN PERMATA ANGGUN P', 2, '081'),
(31, '3120922364', 'MUHAMMAD KHOIRUN NIZAM', 2, '081'),
(32, '0126548047', 'MUHAMMAD RAFAEL PRADIPTA', 2, '081'),
(33, '0126255000', 'AHMAD TSAQIF AHNAFI', 2, '081'),
(34, '0129661306', 'AHMAD DAFIQ PRAYOGA', 2, '081'),
(35, '3127032188', 'AKHMAD NOVAL KHOIRUZAIN', 2, '081'),
(36, '0129955211', 'RIO SULISTYO NUGROHO', 2, '081'),
(37, '0121702487', 'LAILI FITRIANI NINGRUM', 2, '081'),
(38, '0134275978', 'SYAFIQA TALITA AZZAHRA', 2, '081'),
(39, '3137521038', 'MUHAMMAD FERI KURNIAWAN', 2, '081'),
(40, '3133093037', 'MALIK ABDULLOH', 2, '081'),
(41, '3137714649', 'MUHAMMAD SYAHRUL IRWANA', 2, '081'),
(42, '0126897307', 'HERLIAN ADI PAMUNGKAS', 2, '081'),
(43, '3124395342', 'AHMAD NUR IHSAN', 2, '081'),
(44, '3133557609', 'MUHAMMAD RIDWAN', 2, '081'),
(45, '3137869974', 'MUHAMMAD ALFIN AL AZMI', 2, '081'),
(46, '3133361025', 'LEATICIA PUTRI NISA', 2, '081'),
(47, '3125828090', 'SILVIA DAMAYANTI', 2, '081'),
(48, '3129134047', 'SURYA RIZKI ISTAHIR', 2, '081'),
(49, '0129192626', 'NURROHMAH AFIKA PUTRI', 2, '081'),
(50, '3139289611', 'MAURA BELA ANATASYA', 2, '081'),
(51, '3138297454', 'MUHAMMAD FARIS IKHWAN', 2, '081'),
(52, '3139220142', 'MUHAMMAD ERLANGGA ZAIN AL AMIR', 2, '081'),
(53, '0133225928', 'NAJWA KHOIRO', 2, '081'),
(54, '3138339957', 'AHMAD RIZQI ADITIYA SAPUTRA', 3, '081'),
(55, '3139574590', 'MUHAMMAD ALVIN NADZIRUL MUNA', 3, '081'),
(56, '3132568945', 'DINI VAHRIA', 3, '081'),
(57, '3127058210', 'MUHAMMAD MIFTAHUR ROJAB', 3, '081'),
(58, '3138309810', 'NAZILA AINUR ROHMAH', 3, '081'),
(59, '0126622210', 'AHMAD KEVIN ANANDA SAPUTRA', 3, '081'),
(60, '3135412209', 'DELLA NOVITA YULIANI', 3, '081'),
(61, '3131308747', 'KHABIBATUN NAILIL MUNA', 3, '081'),
(62, '3139198555', 'ROBBI AL AMIN KHALLAQ', 3, '081'),
(63, '3131600918', 'YUAN PUTRA PRATAMA', 3, '081'),
(64, '3121217447', 'BILLY SATRIA', 3, '081'),
(65, '3132127563', 'RAFA TABIUL KURNIAWAN', 3, '081'),
(66, '3124023955', 'SEPTIAN NURIL ABADI', 3, '081'),
(67, '0123731594', 'FATIMAH AZZAHRA', 3, '081'),
(68, '3131223500', 'MADLAIL YUWAS SAKETI', 3, '081'),
(69, '0134606342', 'TSABUT IZZUL HAQ', 3, '081'),
(70, '0131729851', 'ALFIA MAHARANI', 3, '081'),
(71, '3120333705', 'FATIMATUL ZAHRA', 3, '081'),
(72, '3132717098', 'RIZKI RAMNDAN MAULANA', 3, '081'),
(73, '0128520443', 'AHMAD FAIZ MAULANA', 3, '081'),
(74, '3121787034', 'M. AGUNG KURNIAWAN RAMADHAN', 3, '081'),
(75, '3127199671', 'DIAN FATMALA', 3, '081'),
(76, '0132389034', 'MUHAMMAD SULTON KHASANUDIN', 3, '081'),
(77, '3139831259', 'KELVIN ARYA SAPUTRA', 3, '081'),
(78, '0125843423', 'AHMAD FARIS MAULANA', 3, '081'),
(79, '3131297892', 'MUHAMMAD ATALY HALWANY', 3, '081'),
(80, '3128324451', 'AHMAD SABILILLAHI DHAKKA', 3, '081'),
(81, '0123894265', 'KHOIRUN NIZAM', 3, '081'),
(82, '3120755676', 'ADINDA RISTYA NAJWA', 4, '081'),
(83, '0114351452', 'ADZSA SURYA ANARA', 4, '081'),
(84, '3122585446', 'AZZAHRA ASSYLA VELISA', 4, '081'),
(85, '3124450767', 'CARERA AQILA', 4, '081'),
(86, '0114544206', 'IRVIATUN NI\'MATUR RIZQIYAH', 4, '081'),
(87, '3130167157', 'KEYSA AULIA ZAHRA', 4, '081'),
(88, '0113616965', 'MUHAMAD NOVIAN RAHMAN PUTRA', 4, '081'),
(89, '3119265005', 'MUHAMMAD ADITYA FIRMANSYAH', 4, '081'),
(90, '0125200944', 'MUHAMMAD WILDAN KHIKMAWAN', 4, '081'),
(91, '3128831089', 'NADIA NURIFIANA', 4, '081'),
(92, '0114318397', 'PUTRI SUSILAWATI', 4, '081'),
(93, '3122266966', 'SANDRA AULIA', 4, '081'),
(94, '0119226367', 'SRI ZUMIATUN', 4, '081'),
(95, '3124769239', 'ULYA TSANIA ZANUBA', 4, '081'),
(96, '0126711469', 'VIDI PUTRA ARDIANSYAH', 4, '081'),
(97, '3126821974', 'POPY MUSTIKA RAMADHANI', 4, '081'),
(98, '0129127859', 'ADITIYA DWI SAPUTRA', 4, '081'),
(99, '0129843168', 'MUHAMMAD FAHMI BISYRI', 4, '081'),
(100, '0121480736', 'M RIZQI AGUNG RAMADHAN', 4, '081'),
(101, '3105012867', 'MAULANA ROMANDHON', 4, '081'),
(102, '0123135211', 'WAKHIDATUN ANISA', 4, '081'),
(103, '0128721367', 'RAHID MUWAFIQUL \'AZZAM', 4, '081'),
(104, '0121103041', 'MUHAMMAD ARMANUL HAKIM', 4, '081'),
(105, '0111481247', 'MUHAMMAD SIFA\'UL MUROFFIKI', 4, '081'),
(106, '3126443359', 'FATICHATUL MAFAZA', 4, '081'),
(107, '0109958605', 'ADHIETYIA PUTRA HENDRAWAN', 5, '081'),
(108, '3112456930', 'AFIFA NAHDA RAFANDA', 5, '081'),
(109, '0123900848', 'AHMAD RENDY PRATAMA', 5, '081'),
(110, '0116267101', 'ALIF FIKRI', 5, '081'),
(111, '3118831620', 'DANANG EKA SAPUTRA', 5, '081'),
(112, '0118547184', 'DWI LAILATUL MAULIDA', 5, '081'),
(113, '3126702299', 'FEBRIANA ZAHROH', 5, '081'),
(114, '3112558418', 'GALANG IKHSAN NURSANDI', 5, '081'),
(115, '0117666089', 'HAIKAL ZIDAN ZUHRI', 5, '081'),
(116, '0115085458', 'HILDA NURLUTFIYANA', 5, '081'),
(117, '3137231165', 'JENY FEBRIYANI NUR LAILA', 5, '081'),
(118, '3121504318', 'MUHAMMAD ARIS WILDANUS SHOLIH', 5, '081'),
(119, '0106115897', 'MUHAMMAD FAHRUL RIZQI RAMADHAN', 5, '081'),
(120, '0129804452', 'MUHAMMAD KHOIRUL ANAM', 5, '081'),
(121, '0118518677', 'MUHAMMAD NASRULLAH', 5, '081'),
(122, '0117135346', 'NOVI NUR MALASARI', 5, '081'),
(123, '3112320841', 'RENI RISWANDA', 5, '081'),
(124, '3127363937', 'TITIK SAHARA', 5, '081'),
(125, '3127960211', 'MUHAMMAD FAHRIS BAYKHAQI', 5, '081'),
(126, '3117413004', 'MUHAMMAD REZA MAULANA', 5, '081'),
(127, '3119381594', 'SINTA NADIA NURUNNAJWA', 5, '081'),
(128, '0115485868', 'HANNY ALYA NOVIYANI', 5, '081'),
(129, '0129852379', 'ZULVIA NUR ANDINI', 5, '081'),
(130, '0122629624', 'PUTRI WAHYU SETYANINGSIH', 5, '081'),
(131, '0123639421', 'MUHAMMAD BAGAS ARFI\'AN', 5, '081'),
(132, '0115805425', 'SULIS SETIAWATI', 5, '081'),
(133, '3123330170', 'MUHAMMAD DANIZ APRILIANSYAH', 5, '081'),
(134, '3121019888', 'AHMAD RIZKI AINUR ROMANDHON', 6, '081'),
(135, '0115790295', 'AHMAD ROKHIM RAMDHANI', 6, '081'),
(136, '3126837688', 'ALINE SAFIRA', 6, '081'),
(137, '0117895233', 'AMANDA EVA LUTFIANA', 6, '081'),
(138, '0122976511', 'ARTIKA ARZA SARI', 6, '081'),
(139, '3126736090', 'ASHFA SAYYIDATUR ROHMANIYAH', 6, '081'),
(140, '0113629068', 'ERLI ANGGUN SIFATI', 6, '081'),
(141, '3113387919', 'FITRIA PUTRI ALIF CINTA MILLATURRAHMA', 6, '081'),
(142, '3111021302', 'MELISA INTAN NUR AYUNI', 6, '081'),
(143, '3116628782', 'MEYSHA APRILLIA', 6, '081'),
(144, '3128909812', 'MUHAJIR ILYAS EFENDI', 6, '081'),
(145, '3114653918', 'RIMAS FIANA', 6, '081'),
(146, '3128991502', 'SATRIA AZKA PRAYOGA', 6, '081'),
(147, '3121124418', 'SYARIF IBNI ILMI', 6, '081'),
(148, '0116596979', 'MUHAMMAD ALFIN AL ISLAH', 6, '081'),
(149, '3135513443', 'SYIFA NABILA', 6, '081'),
(150, '3127855357', 'YUHANA PUTRI LESTARI', 6, '081'),
(151, '0129635556', 'MUHAMMAD FAIZ MAULANA', 6, '081'),
(152, '3134023964', 'MUHAMMAD SIROJJUDIN', 6, '081'),
(153, '3118699460', 'MUHAMMAD FAIZUL ANWAR', 6, '081'),
(154, '3124007649', 'AYU RAHMAWATI', 6, '081'),
(155, '0129209763', 'LILIS SETYAWATI', 6, '081'),
(156, '0125549261', 'MUHAMMAD AFIF ALFIYAN', 6, '081'),
(157, '3124210405', 'MUHAMMAD KHAIDAR YAHYA', 6, '081'),
(158, '0111725542', 'REZA JOHAN SAPUTRA', 6, '081'),
(159, '0123503542', 'MUHAMMAD KHA\'IZ ALFIYAN', 6, '081'),
(160, '3126390074', 'BERLINA VELISA PUTRI', 7, '081'),
(161, '0102504592', 'ADIRA EBI FIRMANSYAH', 7, '081'),
(162, '123150362', 'AHMAD KHOIRON NIAM', 7, '081'),
(163, '3117650451', 'ALFINO RIZKI KURNIA', 7, '081'),
(164, '124433840', 'ANISATUL ALIYAH', 7, '081'),
(165, '3128774582', 'DEANOVA ALIF DEO PRADANA', 7, '081'),
(166, '3113854748', 'ELVIA NAYSA FAKHIROH', 7, '081'),
(167, '0124085660', 'FARAH DWI CANTIKA', 7, '081'),
(168, '0116257375', 'FITHRIYA DEWI ANGGRAINI', 7, '081'),
(169, '0127430955', 'IMELDA SULISTIYOWATI', 7, '081'),
(170, '3124258696', 'MUHAMMAD AHYA RIZKA PRATAMA', 7, '081'),
(171, '0125975524', 'MUHAMMAD KHOIRUN NIZAM', 7, '081'),
(172, '0123137950', 'MUHAMMAD WILDAN ASSAUQI', 7, '081'),
(173, '0128128113', 'NAJWA FARIDATUS SAFIRA', 7, '081'),
(174, '3116876017', 'SALSA AULIA HASANAH', 7, '081'),
(175, '3123215447', 'ALYA ADRIANA', 7, '081'),
(176, '0118498242', 'MUHAMMAD EKA AFRIYANTO', 7, '081'),
(177, '3120091294', 'KARISA BELA MELANI PUTRI', 7, '081'),
(178, '0125698428', 'RISTI RAMADHANI', 7, '081'),
(179, '0105627200', 'MUHAMMAD KHOIRUL UMAM', 7, '081'),
(180, '0121676624', 'MUHAMMAD TAZA ALVINO', 7, '081'),
(181, '0118550147', 'M. ALFINO RIZKI AWWALU', 7, '081'),
(182, '0111977938', 'MUHAMMAD RISQI FERDIYANSYAH', 7, '081');

--
-- Indexes for dumped tables
--

--
-- Indeks untuk tabel `absensi`
--
ALTER TABLE `absensi`
  ADD PRIMARY KEY (`id`),
  ADD KEY `siswa_id` (`siswa_id`);

--
-- Indeks untuk tabel `kelas`
--
ALTER TABLE `kelas`
  ADD PRIMARY KEY (`id`);

--
-- Indeks untuk tabel `siswa`
--
ALTER TABLE `siswa`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `nis` (`nis`),
  ADD KEY `kelas_id` (`kelas_id`);

--
-- AUTO_INCREMENT untuk tabel yang dibuang
--

--
-- AUTO_INCREMENT untuk tabel `absensi`
--
ALTER TABLE `absensi`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT untuk tabel `kelas`
--
ALTER TABLE `kelas`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8;

--
-- AUTO_INCREMENT untuk tabel `siswa`
--
ALTER TABLE `siswa`
  MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=183;

--
-- Ketidakleluasaan untuk tabel pelimpahan (Dumped Tables)
--

--
-- Ketidakleluasaan untuk tabel `absensi`
--
ALTER TABLE `absensi`
  ADD CONSTRAINT `absensi_ibfk_1` FOREIGN KEY (`siswa_id`) REFERENCES `siswa` (`id`) ON DELETE CASCADE;

--
-- Ketidakleluasaan untuk tabel `siswa`
--
ALTER TABLE `siswa`
  ADD CONSTRAINT `siswa_ibfk_1` FOREIGN KEY (`kelas_id`) REFERENCES `kelas` (`id`) ON DELETE CASCADE;
COMMIT;

