
CREATE TABLE `available_day_ranges` (
  `id` bigint UNSIGNED NOT NULL,
  `person_id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `sunday` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `monday` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `tuesday` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `wednesday` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `thursday` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `friday` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `saturday` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Volcado de datos para la tabla `available_day_ranges`
--

INSERT INTO `available_day_ranges` (`id`, `person_id`, `sunday`, `monday`, `tuesday`, `wednesday`, `thursday`, `friday`, `saturday`, `created_at`, `updated_at`) VALUES
(3, 'a33f103a-4b34-41a4-8dda-b7717a4b3a8d', '[\"1:00 - 2:00\",\"2:00 - 3:00\",\"3:00 - 4:00\"]', 'null', 'null', 'null', 'null', 'null', '[\"20:00 - 21:00\"]', '2023-10-06 03:12:28', '2023-10-06 03:27:22');

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

--
-- Estructura de tabla para la tabla `classes`
--

CREATE TABLE `classes` (
  `id` bigint UNSIGNED NOT NULL,
  `person_teacher_id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `person_student_id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `meeting_id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `language_id` bigint UNSIGNED NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

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

--
-- Estructura de tabla para la tabla `countries`
--

CREATE TABLE `countries` (
  `id` bigint UNSIGNED NOT NULL,
  `code` bigint NOT NULL,
  `country_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `time_zone` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Volcado de datos para la tabla `countries`
--

INSERT INTO `countries` (`id`, `code`, `country_name`, `time_zone`, `created_at`, `updated_at`) VALUES
(1, 58, 'Venezuela', 'GTM-4', NULL, NULL),
(2, 34, 'España ', 'GTM-4', NULL, NULL);

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

--
-- Estructura de tabla para la tabla `currencies`
--

CREATE TABLE `currencies` (
  `id` bigint UNSIGNED NOT NULL,
  `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `simbol` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'S',
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

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

--
-- Estructura de tabla para la tabla `failed_jobs`
--

CREATE TABLE `failed_jobs` (
  `id` bigint UNSIGNED NOT NULL,
  `uuid` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `connection` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `queue` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `payload` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `exception` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `failed_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

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

--
-- Estructura de tabla para la tabla `hour_language_profits`
--

CREATE TABLE `hour_language_profits` (
  `id` bigint UNSIGNED NOT NULL,
  `person_id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `language_id` bigint UNSIGNED NOT NULL,
  `currency_id` bigint UNSIGNED NOT NULL,
  `value` double(8,2) NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

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

--
-- Estructura de tabla para la tabla `languages`
--

CREATE TABLE `languages` (
  `id` bigint UNSIGNED NOT NULL,
  `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Volcado de datos para la tabla `languages`
--

INSERT INTO `languages` (`id`, `name`, `created_at`, `updated_at`) VALUES
(1, 'Spanish', NULL, NULL),
(2, 'Ingles', NULL, NULL);

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

--
-- Estructura de tabla para la tabla `media_attachments`
--

CREATE TABLE `media_attachments` (
  `id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `extension` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `media_type_id` bigint UNSIGNED NOT NULL,
  `person_id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Volcado de datos para la tabla `media_attachments`
--

INSERT INTO `media_attachments` (`id`, `name`, `extension`, `media_type_id`, `person_id`, `created_at`, `updated_at`) VALUES
('9f3fdf91-99ad-4b7b-bcd5-e8151ca7316f', 'UhdOJVRQTl6K.jpeg', 'jpeg', 2, 'a33f103a-4b34-41a4-8dda-b7717a4b3a8d', '2023-09-29 18:02:23', '2023-09-29 18:02:23'),
('ae6f9cd8-5746-454c-8900-778bf87c31be', 'wfOyoHWQofjk.png', 'png', 2, '4c6a9f54-2925-4e08-8848-4808ad0fdd4b', '2023-10-07 20:56:26', '2023-10-07 20:56:26');

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

--
-- Estructura de tabla para la tabla `media_types`
--

CREATE TABLE `media_types` (
  `id` bigint UNSIGNED NOT NULL,
  `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Volcado de datos para la tabla `media_types`
--

INSERT INTO `media_types` (`id`, `name`, `created_at`, `updated_at`) VALUES
(1, 'video', NULL, NULL),
(2, 'profile_picture', NULL, NULL),
(3, 'cv', NULL, NULL);

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

--
-- Estructura de tabla para la tabla `meetings`
--

CREATE TABLE `meetings` (
  `id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `date` datetime NOT NULL,
  `meet_platform_id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

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

--
-- Estructura de tabla para la tabla `migrations`
--

CREATE TABLE `migrations` (
  `id` int UNSIGNED NOT NULL,
  `migration` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `batch` int NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Volcado de datos para la tabla `migrations`
--

INSERT INTO `migrations` (`id`, `migration`, `batch`) VALUES
(1, '2014_10_12_100000_create_password_resets_table', 1),
(2, '2019_08_19_000000_create_failed_jobs_table', 1),
(3, '2019_12_14_000001_create_personal_access_tokens_table', 1),
(4, '2023_08_23_224745_create_people_table', 1),
(5, '2023_08_23_224819_create_users_table', 1),
(6, '2023_08_23_230416_create_roles_table', 1),
(7, '2023_08_23_230641_create_person_types_table', 1),
(8, '2023_08_23_230756_create_phones_table', 1),
(9, '2023_08_23_231129_create_countries_table', 1),
(10, '2023_08_23_231533_create_languages_table', 1),
(11, '2023_08_23_231554_create_teach_languages_table', 1),
(12, '2023_08_23_231737_create_native_languages_table', 1),
(13, '2023_08_23_232114_create_currencies_table', 1),
(14, '2023_08_23_232251_create_hour_language_profits_table', 1),
(15, '2023_08_23_232724_create_meeting_platforms_table', 1),
(16, '2023_08_23_232725_create_meetings_table', 1),
(17, '2023_08_23_232726_create_classes_table', 1),
(18, '2023_08_24_024935_create_platform_data_access_table', 1),
(19, '2023_09_04_131236_create_teach_experiences_table', 1),
(20, '2023_09_14_002020_create_table_media_types', 1),
(21, '2023_09_15_005729_create_table_media_attachments', 1),
(22, '2023_09_19_015244_create_payment_platforms_table', 1),
(23, '2023_09_19_015358_create_personal_payment_accounts_table', 1),
(24, '2023_09_27_010230_search_preferences', 2),
(25, '2023_09_27_011028_available_day_ranges', 2);

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

--
-- Estructura de tabla para la tabla `native_languages`
--

CREATE TABLE `native_languages` (
  `id` bigint UNSIGNED NOT NULL,
  `person_id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `language_id` bigint UNSIGNED NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Volcado de datos para la tabla `native_languages`
--

INSERT INTO `native_languages` (`id`, `person_id`, `language_id`, `created_at`, `updated_at`) VALUES
(1, '5b92b3b0-e980-4f3a-bd4c-302faab98fe1', 1, '2023-09-24 07:48:22', '2023-09-24 07:48:22'),
(2, 'a33f103a-4b34-41a4-8dda-b7717a4b3a8d', 1, '2023-09-24 07:50:43', '2023-09-24 07:50:43');

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

--
-- Estructura de tabla para la tabla `payment_platforms`
--

CREATE TABLE `payment_platforms` (
  `id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `platform` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

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

--
-- Estructura de tabla para la tabla `people`
--

CREATE TABLE `people` (
  `id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `surname_first` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `surname_second` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `website` varchar(1000) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `birthdate` date NOT NULL,
  `person_type_id` bigint NOT NULL,
  `country_id` bigint NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL,
  `deleted_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Volcado de datos para la tabla `people`
--

INSERT INTO `people` (`id`, `name`, `surname_first`, `surname_second`, `website`, `birthdate`, `person_type_id`, `country_id`, `created_at`, `updated_at`, `deleted_at`) VALUES
('06b8ae3d-e873-4291-aaaf-a0669c1e9165', 'Juan', 'pacheco', 'Lugo', NULL, '2023-09-24', 2, 1, '2023-09-24 07:47:48', '2023-09-24 07:47:48', NULL),
('4c6a9f54-2925-4e08-8848-4808ad0fdd4b', 'Juan', 'Lugo', NULL, 'https://www.tu-asistente-virtual.es/', '2023-10-07', 1, 1, '2023-10-07 20:07:39', '2023-10-07 20:35:44', NULL),
('5610851c-c0c7-4fc5-bcc6-9655d9a6e297', 'Juan', 'Lugo', NULL, NULL, '2023-09-26', 1, 1, '2023-09-26 20:09:04', '2023-09-26 20:09:04', NULL),
('5b92b3b0-e980-4f3a-bd4c-302faab98fe1', 'Juan', 'pacheco', 'Lugo', NULL, '2023-09-24', 2, 1, '2023-09-24 07:48:22', '2023-09-24 07:48:22', NULL),
('a33f103a-4b34-41a4-8dda-b7717a4b3a8d', 'Juan antonio', 'pacheco', 'Lugo', NULL, '2023-09-24', 1, 1, '2023-09-24 07:50:43', '2023-09-24 21:34:31', NULL);

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

--
-- Estructura de tabla para la tabla `personal_payment_accounts`
--

CREATE TABLE `personal_payment_accounts` (
  `id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `person_id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `payment_platform_id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `details` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

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

--
-- Estructura de tabla para la tabla `person_types`
--

CREATE TABLE `person_types` (
  `id` bigint UNSIGNED NOT NULL,
  `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Volcado de datos para la tabla `person_types`
--

INSERT INTO `person_types` (`id`, `name`, `created_at`, `updated_at`) VALUES
(1, 'Students', NULL, NULL),
(2, 'Teachers', NULL, NULL);

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

--
-- Estructura de tabla para la tabla `phones`
--

CREATE TABLE `phones` (
  `id` bigint UNSIGNED NOT NULL,
  `person_id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `code_country` bigint NOT NULL,
  `phone_number` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Volcado de datos para la tabla `phones`
--

INSERT INTO `phones` (`id`, `person_id`, `code_country`, `phone_number`, `created_at`, `updated_at`) VALUES
(8, '4c6a9f54-2925-4e08-8848-4808ad0fdd4b', 58, '4144604394', '2023-10-07 20:07:39', '2023-10-07 20:07:39');

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

--
-- Estructura de tabla para la tabla `roles`
--

CREATE TABLE `roles` (
  `id` bigint UNSIGNED NOT NULL,
  `role_unique_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `description` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Volcado de datos para la tabla `roles`
--

INSERT INTO `roles` (`id`, `role_unique_name`, `description`, `created_at`, `updated_at`) VALUES
(1, 'teacher', 'teacher', NULL, NULL),
(2, 'student', 'student', NULL, NULL);

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

--
-- Estructura de tabla para la tabla `search_preferences`
--

CREATE TABLE `search_preferences` (
  `id` bigint UNSIGNED NOT NULL,
  `person_id` char(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `language_id` bigint UNSIGNED NOT NULL,
  `informacion_1` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `informacion_2` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `informacion_3` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `informacion_4` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
  `created_at` timestamp NULL DEFAULT NULL,
  `updated_at` timestamp NULL DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Volcado de datos para la tabla `search_preferences`
--

INSERT INTO `search_preferences` (`id`, `person_id`, `language_id`, `informacion_1`, `informacion_2`, `informacion_3`, `informacion_4`, `created_at`, `updated_at`) VALUES
(7, 'a33f103a-4b34-41a4-8dda-b7717a4b3a8d', 2, 'Vivir en el extrangero', 'Avanzado (Hablo y me entienden, pero deseo hablar con mayor fluidez)', '2', '2', '2023-09-29 18:01:47', '2023-10-03 02:49:07');

--
-- Índices para tablas volcadas
--

--
-- Indices de la tabla `available_day_ranges`
--
ALTER TABLE `available_day_ranges`
  ADD PRIMARY KEY (`id`),
  ADD KEY `available_day_ranges_person_id_foreign` (`person_id`);

--
-- Indices de la tabla `classes`
--
ALTER TABLE `classes`
  ADD PRIMARY KEY (`id`),
  ADD KEY `classes_person_teacher_id_foreign` (`person_teacher_id`),
  ADD KEY `classes_person_student_id_foreign` (`person_student_id`),
  ADD KEY `classes_meeting_id_foreign` (`meeting_id`),
  ADD KEY `classes_language_id_foreign` (`language_id`);

--
-- Indices de la tabla `countries`
--
ALTER TABLE `countries`
  ADD PRIMARY KEY (`id`);

--
-- Indices de la tabla `currencies`
--
ALTER TABLE `currencies`
  ADD PRIMARY KEY (`id`);

--
-- Indices de la tabla `failed_jobs`
--
ALTER TABLE `failed_jobs`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `failed_jobs_uuid_unique` (`uuid`);

--
-- Indices de la tabla `hour_language_profits`
--
ALTER TABLE `hour_language_profits`
  ADD PRIMARY KEY (`id`),
  ADD KEY `hour_language_profits_person_id_foreign` (`person_id`),
  ADD KEY `hour_language_profits_language_id_foreign` (`language_id`),
  ADD KEY `hour_language_profits_currency_id_foreign` (`currency_id`);

--
-- Indices de la tabla `languages`
--
ALTER TABLE `languages`
  ADD PRIMARY KEY (`id`);

--
-- Indices de la tabla `media_attachments`
--
ALTER TABLE `media_attachments`
  ADD PRIMARY KEY (`id`),
  ADD KEY `media_attachments_media_type_id_foreign` (`media_type_id`),
  ADD KEY `media_attachments_person_id_foreign` (`person_id`);

--
-- Indices de la tabla `media_types`
--
ALTER TABLE `media_types`
  ADD PRIMARY KEY (`id`);

--
-- Indices de la tabla `meetings`
--
ALTER TABLE `meetings`
  ADD PRIMARY KEY (`id`),
  ADD KEY `meetings_meet_platform_id_foreign` (`meet_platform_id`);

--
-- Indices de la tabla `migrations`
--
ALTER TABLE `migrations`
  ADD PRIMARY KEY (`id`);

--
-- Indices de la tabla `native_languages`
--
ALTER TABLE `native_languages`
  ADD PRIMARY KEY (`id`),
  ADD KEY `native_languages_person_id_foreign` (`person_id`),
  ADD KEY `native_languages_language_id_foreign` (`language_id`);

--
-- Indices de la tabla `payment_platforms`
--
ALTER TABLE `payment_platforms`
  ADD PRIMARY KEY (`id`);

--
-- Indices de la tabla `people`
--
ALTER TABLE `people`
  ADD PRIMARY KEY (`id`);

--
-- Indices de la tabla `personal_payment_accounts`
--
ALTER TABLE `personal_payment_accounts`
  ADD PRIMARY KEY (`id`),
  ADD KEY `personal_payment_accounts_person_id_foreign` (`person_id`),
  ADD KEY `personal_payment_accounts_payment_platform_id_foreign` (`payment_platform_id`);

--
-- Indices de la tabla `person_types`
--
ALTER TABLE `person_types`
  ADD PRIMARY KEY (`id`);

--
-- Indices de la tabla `phones`
--
ALTER TABLE `phones`
  ADD PRIMARY KEY (`id`),
  ADD KEY `phones_person_id_foreign` (`person_id`);

--
-- Indices de la tabla `roles`
--
ALTER TABLE `roles`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `roles_role_unique_name_unique` (`role_unique_name`);

--
-- Indices de la tabla `search_preferences`
--
ALTER TABLE `search_preferences`
  ADD PRIMARY KEY (`id`),
  ADD UNIQUE KEY `language_id` (`language_id`),
  ADD KEY `search_preferences_person_id_foreign` (`person_id`);

--
-- AUTO_INCREMENT de las tablas volcadas
--

--
-- AUTO_INCREMENT de la tabla `available_day_ranges`
--
ALTER TABLE `available_day_ranges`
  MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4;

--
-- AUTO_INCREMENT de la tabla `classes`
--
ALTER TABLE `classes`
  MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT de la tabla `countries`
--
ALTER TABLE `countries`
  MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4;

--
-- AUTO_INCREMENT de la tabla `currencies`
--
ALTER TABLE `currencies`
  MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT de la tabla `failed_jobs`
--
ALTER TABLE `failed_jobs`
  MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT de la tabla `hour_language_profits`
--
ALTER TABLE `hour_language_profits`
  MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT;

--
-- AUTO_INCREMENT de la tabla `languages`
--
ALTER TABLE `languages`
  MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;

--
-- AUTO_INCREMENT de la tabla `media_types`
--
ALTER TABLE `media_types`
  MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4;

--
-- AUTO_INCREMENT de la tabla `migrations`
--
ALTER TABLE `migrations`
  MODIFY `id` int UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=26;

--
-- AUTO_INCREMENT de la tabla `native_languages`
--
ALTER TABLE `native_languages`
  MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;

--
-- AUTO_INCREMENT de la tabla `person_types`
--
ALTER TABLE `person_types`
  MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;

--
-- AUTO_INCREMENT de la tabla `phones`
--
ALTER TABLE `phones`
  MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=9;

--
-- AUTO_INCREMENT de la tabla `roles`
--
ALTER TABLE `roles`
  MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;

--
-- AUTO_INCREMENT de la tabla `search_preferences`
--
ALTER TABLE `search_preferences`
  MODIFY `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=10;

--
-- Restricciones para tablas volcadas
--

--
-- Filtros para la tabla `available_day_ranges`
--
ALTER TABLE `available_day_ranges`
  ADD CONSTRAINT `available_day_ranges_person_id_foreign` FOREIGN KEY (`person_id`) REFERENCES `people` (`id`);

--
-- Filtros para la tabla `classes`
--
ALTER TABLE `classes`
  ADD CONSTRAINT `classes_language_id_foreign` FOREIGN KEY (`language_id`) REFERENCES `languages` (`id`),
  ADD CONSTRAINT `classes_meeting_id_foreign` FOREIGN KEY (`meeting_id`) REFERENCES `meetings` (`id`),
  ADD CONSTRAINT `classes_person_student_id_foreign` FOREIGN KEY (`person_student_id`) REFERENCES `people` (`id`),
  ADD CONSTRAINT `classes_person_teacher_id_foreign` FOREIGN KEY (`person_teacher_id`) REFERENCES `people` (`id`);

--
-- Filtros para la tabla `hour_language_profits`
--
ALTER TABLE `hour_language_profits`
  ADD CONSTRAINT `hour_language_profits_currency_id_foreign` FOREIGN KEY (`currency_id`) REFERENCES `currencies` (`id`),
  ADD CONSTRAINT `hour_language_profits_language_id_foreign` FOREIGN KEY (`language_id`) REFERENCES `languages` (`id`),
  ADD CONSTRAINT `hour_language_profits_person_id_foreign` FOREIGN KEY (`person_id`) REFERENCES `people` (`id`);

--
-- Filtros para la tabla `media_attachments`
--
ALTER TABLE `media_attachments`
  ADD CONSTRAINT `media_attachments_media_type_id_foreign` FOREIGN KEY (`media_type_id`) REFERENCES `media_types` (`id`),
  ADD CONSTRAINT `media_attachments_person_id_foreign` FOREIGN KEY (`person_id`) REFERENCES `people` (`id`);

--
-- Filtros para la tabla `meetings`
--
ALTER TABLE `meetings`
  ADD CONSTRAINT `meetings_meet_platform_id_foreign` FOREIGN KEY (`meet_platform_id`) REFERENCES `meeting_platforms` (`id`);

--
-- Filtros para la tabla `native_languages`
--
ALTER TABLE `native_languages`
  ADD CONSTRAINT `native_languages_language_id_foreign` FOREIGN KEY (`language_id`) REFERENCES `languages` (`id`),
  ADD CONSTRAINT `native_languages_person_id_foreign` FOREIGN KEY (`person_id`) REFERENCES `people` (`id`);

--
-- Filtros para la tabla `personal_payment_accounts`
--
ALTER TABLE `personal_payment_accounts`
  ADD CONSTRAINT `personal_payment_accounts_payment_platform_id_foreign` FOREIGN KEY (`payment_platform_id`) REFERENCES `payment_platforms` (`id`),
  ADD CONSTRAINT `personal_payment_accounts_person_id_foreign` FOREIGN KEY (`person_id`) REFERENCES `people` (`id`);

--
-- Filtros para la tabla `phones`
--
ALTER TABLE `phones`
  ADD CONSTRAINT `phones_person_id_foreign` FOREIGN KEY (`person_id`) REFERENCES `people` (`id`);

--
-- Filtros para la tabla `search_preferences`
--
ALTER TABLE `search_preferences`
  ADD CONSTRAINT `search_preferences_language_id_foreign` FOREIGN KEY (`language_id`) REFERENCES `languages` (`id`),
  ADD CONSTRAINT `search_preferences_person_id_foreign` FOREIGN KEY (`person_id`) REFERENCES `people` (`id`);
COMMIT;


