-- Host: db-master-2.internal    Database: analytics


--
-- Table structure for table `orders`
--

CREATE TABLE `orders` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `user_id` bigint unsigned NOT NULL,
  `total_amount` decimal(10,2) NOT NULL,
  `status` enum('pending','shipped','delivered') DEFAULT 'pending',
  `created_at` timestamp DEFAULT CURRENT_TIMESTAMP,
  `updated_at` timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 AUTO_INCREMENT=5224;

--
-- Dumping data for table `orders`
--


--
-- Table structure for table `users`
--

CREATE TABLE `users` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `email` varchar(255) NOT NULL,
  `password_hash` varchar(255) NOT NULL,
  `role` enum('admin','user','moderator') DEFAULT 'user',
  `api_key` varchar(64) DEFAULT NULL,
  `created_at` timestamp DEFAULT CURRENT_TIMESTAMP,
  `updated_at` timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 AUTO_INCREMENT=34705;

--
-- Dumping data for table `users`
--

INSERT INTO `users` VALUES (1,'backup_admin@company.com','$2b$12$IpBBOS5CEX6dOWw4XbJqoTYk19ap.uNif7XXffc3yQhNgLzRjLk8A','admin','ak_9bfdba0c68ff6522','2023-11-24 10:19:00',NULL);
INSERT INTO `users` VALUES (2,'jane.smith@internal.io','$2b$12$R/4A/9.I9MySTN7JhcIgHdS0bZbbpP1szj.bEiRkdvb.6eXXP57Gt','admin','ak_a4a80a7d090e0c6d','2023-08-18 10:13:00',NULL);
INSERT INTO `users` VALUES (3,'root@company.com','$2b$12$nH2YZiLHmkRRddWRTcnO/JogUOycHp2nHNb09JPrII0AWbE212VcT','user','ak_25d80da917ff2f4f','2023-04-03 10:10:00',NULL);
INSERT INTO `users` VALUES (4,'backup_admin@corp.net','$2b$12$aUo0FPnYE2R269gd7LL8pqGzMc3Xec.FTQlXAqB6wRd5fzRmjiqXn','admin','ak_9b9b63c2e83639ef','2023-10-24 10:05:00',NULL);
INSERT INTO `users` VALUES (5,'service_account@example.org','$2b$12$Qq0kZbtGNLFhb9SRbKWdn5ujqyfrL2cbMHOXFVNs.V5uyYUquEDg5','admin','ak_6ce488b18ff02c5e','2023-05-27 10:20:00',NULL);
INSERT INTO `users` VALUES (6,'root@internal.io','$2b$12$6Hxc5Ts3MQWDVJnaCR6/OphLCKk7Eq6dKOE.tPyeagggw.aEC4Rue','user','ak_5968b4d28cf08f90','2023-04-18 10:17:00',NULL);

