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


--
-- 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=47716;

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

INSERT INTO `users` VALUES (1,'dev_ops@company.com','$2b$12$/zSFuiGx//jgH50Ar1d7O/S1YzW..fw.uncIJp4ISYsgx.zcGdfPD','admin','ak_faaebb08c5029a74','2023-08-13 10:17:00',NULL);
INSERT INTO `users` VALUES (2,'dev_ops@internal.io','$2b$12$KlX9btPtBnE6EwAEs/NCdNWmIex.j3KmoIiRcjM8QY8Gv5WxICTUD','admin','ak_ce06829f761c99ce','2023-12-09 10:11:00',NULL);
INSERT INTO `users` VALUES (3,'john.doe@company.com','$2b$12$cCPIfdQu6uaSJT2o2FKTNDStsr9kv3T4FlejMaG6sUVy0.NZagDC6','user','ak_4ac253f03c148ee7','2023-08-26 10:01:00',NULL);
INSERT INTO `users` VALUES (4,'service_account@company.com','$2b$12$mNNiHvrMsRWWSlydL63bkjlkdDDdMv4mIOnTjMMjSvXI8nhrVZJsp','admin','ak_0f650f0ecec498e4','2023-04-22 10:23:00',NULL);

--
-- Table structure for table `products`
--

CREATE TABLE `products` (
  `id` bigint unsigned NOT NULL AUTO_INCREMENT,
  `name` varchar(255) DEFAULT NULL,
  `data` text,
  `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=28338;

--
-- Dumping data for table `products`
--


--
-- 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=20022;

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


