text: /*
  SQLyog Ultimate v12.4.1 (64 bit)
  MySQL - 10.1.13-MariaDB : Database - kos
  *********************************************************************
  */
  
  /*!40101 SET NAMES utf8 */;
  
  /*!40101 SET SQL_MODE=''*/;
  
  /*!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 */;
  CREATE DATABASE /*!32312 IF NOT EXISTS*/`kos` /*!40100 DEFAULT CHARACTER SET latin1 */;
  
  USE `kos`;
  
  /*Table structure for table `kos` */
  
  DROP TABLE IF EXISTS `kos`;
  
  CREATE TABLE `kos` (
    `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
    `nama` varchar(200) DEFAULT NULL,
    `alamat` text,
    `latitude` varchar(255) DEFAULT NULL,
    `longitude` varchar(255) DEFAULT NULL,
    `alamat_map` varchar(255) DEFAULT NULL,
    `id_user` bigint(20) unsigned DEFAULT NULL,
    `gambar` varchar(200) DEFAULT NULL COMMENT 'gunakan ; jika gambar lebih dari 1',
    `harga` double DEFAULT NULL,
    `periode_sewa` enum('harian','bulanan','tahunan') DEFAULT 'bulanan',
    PRIMARY KEY (`id`)
  ) ENGINE=InnoDB AUTO_INCREMENT=48 DEFAULT CHARSET=latin1;
  
  
  /*Table structure for table `user` */
  
  DROP TABLE IF EXISTS `user`;
  
  CREATE TABLE `user` (
    `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
    `nama` varchar(200) DEFAULT NULL,
    `username` varchar(200) DEFAULT NULL,
    `password` text,
    `level` enum('pemilik_kos','admin') DEFAULT 'pemilik_kos',
    PRIMARY KEY (`id`)
  ) ENGINE=InnoDB AUTO_INCREMENT=25 DEFAULT CHARSET=latin1;
  
  
  /*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
  /*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
  /*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
  /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
  