-- --------------------------------------------------------
-- Versión del servidor:         5.7.14 - MySQL Community Server (GPL)
-- SO del servidor:              Win32
-- HeidiSQL Versión:             12.6.0.6765
-- --------------------------------------------------------



-- Volcando estructura de base de datos para conectoraf_rubio
CREATE DATABASE IF NOT EXISTS `conectoraf_rubio` /*!40100 DEFAULT CHARACTER SET latin1 */;
USE `conectoraf_rubio`;

-- Volcando estructura para tabla conectoraf_rubio.actualizacion_relacion
CREATE TABLE IF NOT EXISTS `actualizacion_relacion` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `fecha` datetime NOT NULL,
  `estado_relacion_id` int(11) DEFAULT NULL,
  `tipo_accion_id` int(11) DEFAULT NULL,
  `relacion_cabecera_id` int(11) DEFAULT NULL,
  PRIMARY KEY (`id`),
  KEY `fk_actualizacion_relacion_estado_relacion1_idx` (`estado_relacion_id`),
  KEY `fk_actualizacion_relacion_tipo_accion1_idx` (`tipo_accion_id`),
  KEY `fk_actualizacion_relacion_relacion_cabecera1_idx` (`relacion_cabecera_id`),
  CONSTRAINT `fk_actualizacion_relacion_estado_relacion1` FOREIGN KEY (`estado_relacion_id`) REFERENCES `estado_relacion` (`id`) ON DELETE NO ACTION ON UPDATE NO ACTION,
  CONSTRAINT `fk_actualizacion_relacion_relacion_cabecera1` FOREIGN KEY (`relacion_cabecera_id`) REFERENCES `relacion_cabecera` (`id`) ON DELETE NO ACTION ON UPDATE NO ACTION,
  CONSTRAINT `fk_actualizacion_relacion_tipo_accion1` FOREIGN KEY (`tipo_accion_id`) REFERENCES `tipo_accion` (`id`) ON DELETE NO ACTION ON UPDATE NO ACTION
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

-- Volcando datos para la tabla conectoraf_rubio.actualizacion_relacion: ~0 rows (aproximadamente)
DELETE FROM `actualizacion_relacion`;

-- Volcando estructura para tabla conectoraf_rubio.articulo_cliente_web
CREATE TABLE IF NOT EXISTS `articulo_cliente_web` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `cliente_web_id` int(11) DEFAULT NULL,
  `articulo_web_id` int(11) DEFAULT NULL,
  `id_customer` int(11) NOT NULL,
  PRIMARY KEY (`id`),
  KEY `fk_table1_cliente_web1_idx` (`cliente_web_id`),
  KEY `fk_table1_articulo_web1_idx` (`articulo_web_id`),
  CONSTRAINT `FK_74611DCE182CAB7D` FOREIGN KEY (`articulo_web_id`) REFERENCES `articulo_web` (`id`),
  CONSTRAINT `FK_74611DCE411BAB06` FOREIGN KEY (`cliente_web_id`) REFERENCES `cliente_web` (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8;

-- Volcando datos para la tabla conectoraf_rubio.articulo_cliente_web: ~5 rows (aproximadamente)
DELETE FROM `articulo_cliente_web`;
INSERT INTO `articulo_cliente_web` (`id`, `cliente_web_id`, `articulo_web_id`, `id_customer`) VALUES
	(1, 108, 552, 1),
	(2, 108, 595, 2),
	(3, 108, 593, 3),
	(4, 108, 565, 4),
	(5, 108, 597, 5);

-- Volcando estructura para tabla conectoraf_rubio.articulo_web
CREATE TABLE IF NOT EXISTS `articulo_web` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `id_articulo_web` int(11) NOT NULL,
  `id_articulo_afix` int(11) NOT NULL,
  `articulo_af` varchar(45) NOT NULL,
  `fecha_actualizacion` datetime DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4505 DEFAULT CHARSET=utf8;

-- Volcando datos para la tabla conectoraf_rubio.articulo_web: ~431 rows (aproximadamente)
DELETE FROM `articulo_web`;
INSERT INTO `articulo_web` (`id`, `id_articulo_web`, `id_articulo_afix`, `articulo_af`, `fecha_actualizacion`) VALUES
	(354, 396, 10794, '1-96160534', '2020-11-10 12:14:40'),
	(356, 398, 4904, 'BE-38650016', '2020-11-10 12:14:41'),
	(358, 400, 20070, 'BE-70053003', '2020-11-10 12:14:41'),
	(381, 423, 15188, 'CG-0102712', '2020-11-10 12:14:40'),
	(451, 493, 20811, '1-73676132', '2020-11-10 12:14:41'),
	(463, 505, 6705, 'BRU-975092422', '2020-11-10 12:14:40'),
	(518, 560, 16902, 'PY-AI0002822', '2020-11-10 12:14:41'),
	(521, 563, 2999, 'PY-AI0002214', '2020-11-10 12:14:41'),
	(524, 566, 17604, 'AO-DAM1000', '2020-11-10 12:14:40'),
	(526, 568, 19402, 'BE-03403526', '2020-11-10 12:14:41'),
	(529, 571, 17620, 'PEN-EU204337', '2020-11-10 12:14:40'),
	(531, 573, 18380, 'SCALP-03000474', '2020-11-10 12:14:40'),
	(534, 576, 11168, '1-T820010008', '2020-11-10 12:14:41'),
	(541, 583, 11103, '1-T820210008', '2020-11-10 12:14:41'),
	(547, 589, 11112, '1-T820110008', '2020-11-10 12:14:41'),
	(553, 595, 11130, '1-PY500700108', '2020-11-10 12:14:41'),
	(559, 601, 14838, '1-PY501000114', '2020-11-10 12:14:41'),
	(563, 605, 11142, '1-PY500900108', '2020-11-10 12:14:41'),
	(568, 610, 16932, 'AO-008000', '2023-09-13 07:51:56'),
	(573, 615, 20006, 'T-BIOO090034', '2022-12-21 08:30:29'),
	(574, 616, 18980, 'FL-1260406', '2022-10-19 10:30:29'),
	(575, 617, 18979, 'FL-1260506', '2020-11-10 12:14:40'),
	(576, 618, 18978, 'FL-1260606', '2020-11-10 12:14:40'),
	(673, 715, 21129, 'FL-1211506', '2020-11-10 12:14:40'),
	(674, 716, 18956, 'FL-1207406', '2020-11-10 12:14:40'),
	(689, 731, 18970, 'FL-1250506', '2020-11-10 12:14:40'),
	(690, 732, 18967, 'FL-1260106', '2022-10-20 10:48:52'),
	(691, 733, 18966, 'FL-1260206', '2022-10-20 10:50:00'),
	(692, 734, 21113, 'FL-12603', '2022-10-20 11:05:37'),
	(711, 753, 6902, 'IH-4002097614', '2020-11-10 12:14:41'),
	(748, 790, 13304, 'IH-0502018114', '2020-11-10 12:14:41'),
	(776, 818, 5274, 'IH-1902044008', '2020-11-10 12:14:41'),
	(794, 836, 17490, 'IH-3602089120', '2020-11-10 12:14:41'),
	(802, 844, 3508, '1-67400014', '2020-11-10 12:14:41'),
	(820, 862, 20676, 'IH-5394289014', '2020-11-10 12:14:41'),
	(821, 863, 7829, 'BE-16563130', '2023-09-11 11:34:44'),
	(823, 865, 11809, '1-PY503500022', '2020-11-10 12:14:41'),
	(826, 868, 16736, 'SCALP-03000432', '2024-02-02 11:11:27'),
	(827, 869, 13822, '1-T810210011', '2020-11-10 12:14:41'),
	(833, 875, 14251, '1-T830210032', '2020-11-10 12:14:40'),
	(835, 877, 20878, '1-T830210014', '2020-11-10 12:14:40'),
	(838, 880, 20873, 'BE-34045006', '2020-11-10 12:14:41'),
	(840, 882, 10130, 'BE-16480034', '2023-02-01 10:36:30'),
	(843, 885, 8516, 'BX-RX40024', '2020-11-10 12:14:41'),
	(845, 887, 5703, 'BX-B002914', '2020-11-10 12:14:41'),
	(846, 888, 288, '1-100260024', '2024-04-22 13:56:04'),
	(853, 895, 20884, 'T-PROI12260520', '2020-11-10 12:14:40'),
	(861, 903, 10858, '1-94460514', '2020-11-10 12:14:40'),
	(863, 905, 17535, '1-PY503409814', '2020-11-10 12:14:41'),
	(865, 907, 17526, '1-PY503200222', '2020-11-10 12:14:41'),
	(867, 909, 17532, '1-PY503300322', '2020-11-10 12:14:41'),
	(878, 920, 18269, 'T-PRON300022', '2020-11-10 12:14:40'),
	(879, 921, 18272, 'T-PRON400034', '2020-11-10 12:14:40'),
	(880, 922, 18678, 'T-PRON400014', '2020-11-10 12:14:40'),
	(882, 924, 20005, 'T-BION800034', '2020-11-10 12:14:40'),
	(894, 936, 20452, 'T-PRON900034', '2023-09-12 11:44:59'),
	(898, 940, 20922, 'T-PRON710034', '2020-11-10 12:14:40'),
	(906, 948, 20966, 'PY-ISBN40022', '2020-11-10 12:14:40'),
	(908, 950, 16982, 'BE-PY7037724', '2020-11-10 12:14:41'),
	(909, 951, 16725, 'BE-PY7037816', '2020-11-10 12:14:41'),
	(912, 954, 20007, 'T-BIOQ900034', '2022-12-21 08:26:48'),
	(913, 955, 18276, 'T-PROO100034', '2020-11-10 12:14:40'),
	(917, 959, 20103, 'BX-RX40734', '2020-11-10 12:14:41'),
	(920, 962, 18402, 'T-PROQ500622', '2023-09-13 09:39:28'),
	(922, 964, 2125, 'PY-IS068SE14', '2020-11-10 12:14:41'),
	(923, 965, 3974, 'AO-610016', '2020-11-10 12:14:40'),
	(937, 979, 19084, 'T-T056620', '2020-11-10 12:14:41'),
	(992, 1034, 19123, 'T-T251614', '2020-11-10 12:14:41'),
	(1031, 1073, 19574, 'T-T151614', '2020-11-10 12:14:41'),
	(1035, 1077, 16658, 'BE-03406016', '2023-09-13 07:53:19'),
	(1036, 1078, 20080, 'BE-70447016', '2023-09-13 08:04:48'),
	(1072, 1114, 15131, 'MTN-940140270M', '2020-11-28 09:12:51'),
	(1202, 1244, 10011, 'MTN-940145018M', '2020-11-28 09:12:51'),
	(1269, 1311, 14879, 'PY-IS071BR14', '2020-11-28 08:59:57'),
	(1272, 1314, 20330, 'T-13100004', '2020-11-28 08:59:57'),
	(1275, 1317, 14918, '1-T852450014', '2021-01-28 11:16:19'),
	(1277, 1319, 14916, '1-T852350014', '2021-01-28 11:16:19'),
	(1279, 1321, 14880, 'PY-IS071ST14', '2020-11-28 08:59:57'),
	(1294, 1336, 20329, 'T-12100034', '2020-11-28 08:59:57'),
	(1297, 1339, 20316, 'T-11100014', '2020-11-28 08:59:57'),
	(1307, 1349, 20299, 'T-10100014', '2020-11-28 08:59:57'),
	(1308, 1350, 14914, '1-T852150014', '2021-01-28 11:16:19'),
	(1357, 1399, 16218, 'MTN-HA014H8017', '2020-11-28 09:12:50'),
	(1388, 1430, 12921, 'MTN-HA014H4003', '2020-11-28 09:12:50'),
	(1459, 1501, 16002, 'IX-9524662214', '2020-11-28 08:59:57'),
	(1471, 1513, 16745, 'PY-IS10300014', '2020-11-28 08:59:57'),
	(1479, 1521, 16014, 'IX-9524821414', '2020-11-28 08:59:57'),
	(1490, 1532, 16159, 'IX-0005004808', '2023-03-07 12:14:29'),
	(1491, 1533, 14922, '3-T850100314', '2020-11-28 08:59:57'),
	(1493, 1535, 14868, '3-T850400314', '2020-11-28 08:59:57'),
	(1496, 1538, 14927, '3-T850300322', '2020-11-28 08:59:57'),
	(1497, 1539, 14926, '3-T850300314', '2020-11-28 08:59:57'),
	(1508, 1550, 7753, 'IX-0100001511', '2020-11-28 08:59:57'),
	(1539, 1581, 7738, 'IX-2000041111', '2020-11-28 08:59:57'),
	(1561, 1603, 20345, 'T-52000104', '2020-11-28 08:59:57'),
	(1562, 1604, 7774, 'IX-0005011916', '2020-11-28 08:59:57'),
	(1566, 1608, 7785, 'IX-0005003424', '2020-11-28 08:59:57'),
	(1568, 1610, 7756, 'IX-0005006514', '2023-03-07 12:14:26'),
	(1586, 1628, 18582, 'RH-1SY03445050', '2020-11-28 08:59:57'),
	(1784, 1629, 17619, 'PEN-EU204003', '2020-11-10 12:14:40'),
	(1970, 1539, 14925, '3-T850200322', '2020-11-28 08:59:57'),
	(2069, 2110, 19324, 'RH-1BL01571089', '2021-01-28 11:16:19'),
	(2072, 2113, 20473, 'PY-RD27620', '2021-01-28 11:16:20'),
	(2073, 2114, 18704, 'RH-1SY05005139', '2021-01-28 11:16:19'),
	(2076, 2117, 20334, 'T-16100034', '2021-01-28 11:16:19'),
	(2077, 2118, 20333, 'T-16100004', '2021-01-28 11:16:19'),
	(2078, 2119, 20336, 'T-17100034', '2021-01-28 11:16:19'),
	(2079, 2120, 20335, 'T-17100004', '2021-01-28 11:16:19'),
	(2080, 2121, 17016, 'AB-T6000', '2021-01-28 11:16:45'),
	(2083, 2124, 19720, 'PY-JE31908', '2021-01-28 11:16:20'),
	(2087, 2128, 438, 'PY-JE31606', '2021-01-28 11:16:20'),
	(2089, 2130, 14583, 'RH-PB20102', '2021-01-28 11:16:19'),
	(2090, 2131, 14584, 'RH-PB20104', '2021-01-28 11:16:19'),
	(2091, 2132, 14585, 'RH-PB20106', '2021-01-28 11:16:19'),
	(2092, 2133, 14586, 'RH-PB20108', '2021-01-28 11:16:19'),
	(2093, 2134, 18738, 'RH-1SY00254419', '2021-01-28 11:16:19'),
	(2094, 2135, 18739, 'RH-1SY00254426', '2021-01-28 11:16:19'),
	(2095, 2136, 18743, 'RH-1SY00254464', '2021-01-28 11:16:19'),
	(2096, 2137, 18740, 'RH-1SY00254433', '2021-01-28 11:16:19'),
	(2097, 2138, 18741, 'RH-1SY00254440', '2021-01-28 11:16:19'),
	(2098, 2139, 18742, 'RH-1SY00254457', '2021-01-28 11:16:19'),
	(2099, 2140, 19563, 'RH-1SY00163643', '2021-01-28 11:16:19'),
	(2101, 2142, 19564, 'RH-1SY00163650', '2021-01-28 11:16:19'),
	(2102, 2143, 18735, 'RH-1SY00163605', '2021-01-28 11:16:19'),
	(2104, 2145, 18736, 'RH-1SY00163636', '2021-01-28 11:16:19'),
	(2105, 2146, 18750, 'RH-1SY00491760', '2022-10-20 16:25:01'),
	(2106, 2147, 16988, 'TE-PY00008107/18', '2021-01-28 11:16:19'),
	(2107, 2148, 16987, 'TE-PY00008107/24', '2021-01-28 11:16:19'),
	(2108, 2149, 16989, 'TE-PY00008107/30', '2021-01-28 11:16:19'),
	(2109, 2150, 16990, 'TE-PY00008107/36', '2021-01-28 11:16:19'),
	(2110, 2151, 16991, 'TE-PY00008107/48', '2021-01-28 11:16:19'),
	(2112, 2153, 17669, 'PY-RPC194334', '2023-12-27 18:26:42'),
	(2114, 2155, 17665, 'RH-APC194492', '2023-09-04 11:17:01'),
	(2116, 2157, 18483, 'AB-56502', '2021-01-28 11:16:45'),
	(2117, 2158, 18485, 'AB-56504', '2021-01-28 11:16:45'),
	(2118, 2159, 18486, 'AB-56506', '2021-01-28 11:16:45'),
	(2119, 2160, 18487, 'AB-56508', '2021-01-28 11:16:45'),
	(2120, 2161, 21097, 'AB-56509', '2021-01-28 11:16:45'),
	(2123, 2164, 17010, 'AB-51960', '2021-01-28 11:16:45'),
	(2124, 2165, 17102, 'AB-51980', '2021-01-28 11:16:45'),
	(2125, 2166, 4995, 'AB-50360', '2021-01-28 11:16:45'),
	(2131, 2172, 16786, 'AB-54120', '2021-01-28 11:16:45'),
	(2132, 2173, 16787, 'AB-54150', '2021-01-28 11:16:45'),
	(2133, 2174, 16788, 'AB-54180', '2021-01-28 11:16:45'),
	(2135, 2176, 17393, 'AB-51100', '2021-01-28 11:16:45'),
	(2136, 2177, 13098, 'AB-51120', '2021-01-28 11:16:45'),
	(2137, 2178, 13097, 'AB-51180', '2021-01-28 11:16:45'),
	(2138, 2179, 10318, 'AB-51240', '2021-01-28 11:16:45'),
	(2139, 2180, 3180, 'AB-51320', '2021-01-28 11:16:45'),
	(2140, 2181, 3178, 'AB-51400', '2021-01-28 11:16:45'),
	(2141, 2182, 18386, 'AB-54508', '2021-01-28 11:16:45'),
	(2142, 2183, 2316, 'AB-55120', '2021-01-28 11:16:45'),
	(2143, 2184, 2370, 'AB-55180', '2021-01-28 11:16:45'),
	(2144, 2185, 14320, 'AB-55240', '2021-01-28 11:16:45'),
	(2145, 2186, 14321, 'AB-55320', '2021-01-28 11:16:45'),
	(2146, 2187, 17380, 'AB-532040', '2021-01-28 11:16:45'),
	(2147, 2188, 17381, 'AB-532060', '2021-01-28 11:16:45'),
	(2148, 2189, 17382, 'AB-532080', '2021-01-28 11:16:45'),
	(2149, 2190, 17513, 'AB-54505', '2021-01-28 11:16:45'),
	(2150, 2191, 17514, 'AB-54507', '2021-01-28 11:16:45'),
	(2151, 2192, 4618, 'AB-C6101', '2023-12-01 08:01:09'),
	(2152, 2193, 18754, 'RH-1SY00371383', '2021-01-28 11:16:19'),
	(2153, 2194, 18751, 'RH-1SY00371352', '2021-01-28 11:16:19'),
	(2154, 2195, 18752, 'RH-1SY00371369', '2021-01-28 11:16:19'),
	(2155, 2196, 18753, 'RH-1SY00371376', '2021-01-28 11:16:19'),
	(2156, 2197, 18755, 'RH-1SY00371390', '2021-01-28 11:16:19'),
	(2173, 2214, 17666, 'RH-APC194579', '2023-09-04 11:23:51'),
	(2174, 2215, 16195, 'RH-APC195007', '2023-09-04 11:28:42'),
	(2178, 2219, 15444, 'RH-1BL05220136', '2021-01-28 11:16:19'),
	(2179, 2220, 17178, 'AB-100120', '2021-01-28 11:16:45'),
	(2180, 2221, 17179, 'AB-100180', '2021-01-28 11:16:45'),
	(2181, 2222, 17180, 'AB-100240', '2021-01-28 11:16:45'),
	(2182, 2223, 17181, 'AB-100320', '2021-01-28 11:16:45'),
	(2184, 2225, 3103, 'AB-20120', '2021-01-28 11:16:45'),
	(2185, 2226, 3102, 'AB-20180', '2021-01-28 11:16:45'),
	(2186, 2227, 2451, 'AB-20220', '2021-01-28 11:16:45'),
	(2187, 2228, 2450, 'AB-20280', '2021-01-28 11:16:45'),
	(2188, 2229, 2449, 'AB-20320', '2021-01-28 11:16:45'),
	(2189, 2230, 2452, 'AB-20400', '2021-01-28 11:16:45'),
	(2190, 2231, 20909, 'AB-20500', '2021-01-28 11:16:45'),
	(2191, 2232, 2448, 'AB-20600', '2021-01-28 11:16:45'),
	(2192, 2233, 2447, 'AB-20800', '2021-01-28 11:16:45'),
	(2193, 2234, 1495, 'AB-21000', '2021-01-28 11:16:45'),
	(2194, 2235, 6972, 'AB-21500', '2021-01-28 11:16:45'),
	(2195, 2236, 6971, 'AB-22000', '2021-01-28 11:16:45'),
	(2196, 2237, 16551, 'RH-1SY05315009', '2021-01-28 11:16:19'),
	(2199, 2240, 7284, 'PY-RP771684100', '2021-01-28 11:16:20'),
	(2200, 2241, 7286, 'PY-RP771681100', '2021-01-28 11:16:20'),
	(2201, 2242, 7288, 'PY-RP771682100', '2021-01-28 11:16:20'),
	(2210, 2251, 19715, 'PY-JE14940', '2021-01-28 11:16:19'),
	(2215, 2256, 13758, 'RH-PB52009', '2021-01-28 11:16:19'),
	(2216, 2257, 13761, 'RH-PB52012', '2021-01-28 11:16:19'),
	(2217, 2258, 13760, 'RH-PB52015', '2021-01-28 11:16:19'),
	(2218, 2259, 12538, 'RH-PB52018', '2021-01-28 11:16:19'),
	(2219, 2260, 9058, 'RH-PB52021', '2021-01-28 11:16:19'),
	(2220, 2261, 9057, 'RH-PB52024', '2021-01-28 11:16:19'),
	(2221, 2262, 9380, 'RH-PB52030', '2021-01-28 11:16:19'),
	(2222, 2263, 9381, 'RH-PB52036', '2021-01-28 11:16:19'),
	(2223, 2264, 13759, 'RH-PB3439100', '2021-01-28 11:16:19'),
	(2224, 2265, 1766, 'RH-PB3439020', '2021-01-28 11:16:19'),
	(2225, 2266, 1774, 'RH-PB3439030', '2021-01-28 11:16:19'),
	(2226, 2267, 13762, 'RH-PB3439040', '2021-01-28 11:16:19'),
	(2227, 2268, 13757, 'RH-PB3439050', '2021-01-28 11:16:19'),
	(2228, 2269, 13763, 'RH-PB3439065', '2021-01-28 11:16:19'),
	(2229, 2270, 13756, 'RH-PB3439075', '2021-01-28 11:16:19'),
	(2230, 2271, 8811, 'PY-JE13618', '2021-01-28 11:16:19'),
	(2237, 2278, 2458, 'NER-P5002610', '2021-01-28 11:16:19'),
	(2238, 2279, 2456, 'NER-P5002615', '2021-01-28 11:16:19'),
	(2239, 2280, 2459, 'NER-P5002630', '2021-01-28 11:16:19'),
	(2240, 2281, 2457, 'NER-P5002645', '2021-01-28 11:16:19'),
	(2241, 2282, 17735, 'PY-JE22106', '2021-01-28 11:16:20'),
	(2253, 2294, 17742, 'PY-JE21206', '2021-01-28 11:16:19'),
	(2265, 2306, 19435, 'SA-10141588', '2021-01-28 11:16:46'),
	(2267, 2308, 19356, 'DIS-04017N201', '2023-11-14 12:16:24'),
	(2268, 2309, 12167, 'DIS-200001', '2021-01-28 11:16:46'),
	(2270, 2311, 19439, 'SA-20140803', '2022-11-17 10:26:18'),
	(2271, 2312, 14517, 'SA-20141904', '2021-01-28 11:16:46'),
	(2272, 2313, 14518, 'SA-20141903', '2021-01-28 11:16:46'),
	(2273, 2314, 14519, 'SA-20141902', '2021-01-28 11:16:46'),
	(2275, 2316, 12289, 'DIS-200002', '2023-09-12 13:14:55'),
	(2276, 2317, 17286, 'WK-500750', '2023-05-11 12:01:43'),
	(2280, 2321, 20516, 'PY-RD24421', '2021-01-28 11:16:20'),
	(2281, 2322, 20515, 'PY-RD24121', '2021-01-28 11:16:20'),
	(2282, 2323, 20518, 'PY-RD24821', '2021-01-28 11:16:20'),
	(2284, 2325, 16194, 'RH-RDR975001', '2021-01-28 11:16:20'),
	(2289, 2330, 20512, 'PY-RD13622', '2024-03-07 00:21:36'),
	(2290, 2331, 20466, 'PY-RD12223', '2023-07-11 11:50:42'),
	(2291, 2332, 19042, 'RH-RDR2188122', '2023-04-26 09:26:34'),
	(2292, 2333, 12064, 'RH-RDR103022', '2023-12-27 18:16:30'),
	(2293, 2334, 19043, 'RH-RDR2177522', '2021-01-28 11:16:20'),
	(2294, 2335, 12041, 'RH-RDR2139125', '2021-01-28 11:16:20'),
	(2295, 2336, 16193, 'RH-RDR975000', '2021-01-28 11:16:20'),
	(2296, 2337, 16210, 'RH-RDR2187922', '2023-03-14 08:52:23'),
	(2297, 2338, 12033, 'RH-RDR236225', '2021-01-28 11:16:20'),
	(2299, 2340, 20513, 'PY-RD12358', '2024-03-07 00:21:28'),
	(2301, 2342, 12065, 'RH-RDR102022', '2021-01-28 11:16:20'),
	(2304, 2345, 10112, 'AB-R8000', '2021-01-28 11:16:45'),
	(2305, 2346, 4044, 'AB-R8104', '2021-01-28 11:16:45'),
	(2306, 2347, 4042, 'AB-R8106', '2021-01-28 11:16:45'),
	(2307, 2348, 4041, 'AB-R8108', '2021-01-28 11:16:45'),
	(2308, 2349, 554, 'AB-R8109', '2021-01-28 11:16:45'),
	(2309, 2350, 10092, 'AB-R8110', '2021-01-28 11:16:45'),
	(2310, 2351, 4047, 'AB-R8100', '2021-01-28 11:16:45'),
	(2311, 2352, 4043, 'AB-R8102', '2021-01-28 11:16:45'),
	(2313, 2354, 17667, 'RH-PSC190695', '2021-01-28 11:16:19'),
	(2314, 2355, 645, 'NER-H5000896', '2021-01-28 11:16:19'),
	(2315, 2356, 16931, 'NER-H5009170', '2021-01-28 11:16:19'),
	(2316, 2357, 2460, 'NER-H5009070', '2021-01-28 11:16:19'),
	(2317, 2358, 20478, 'PY-RD293209', '2021-01-28 11:16:19'),
	(2318, 2359, 2455, 'NER-R5001249', '2021-01-28 11:16:19'),
	(2322, 2363, 4542, 'AB-P79934', '2023-05-16 12:06:31'),
	(2323, 2364, 18707, 'RH-1SY00390384', '2022-10-20 16:24:52'),
	(2324, 2365, 17243, 'TE-0433400001-00', '2021-01-28 11:16:19'),
	(2325, 2366, 17266, 'TE-0433400004-00', '2021-01-28 11:16:19'),
	(2326, 2367, 20413, 'TE-0434400003-00', '2021-01-28 11:16:19'),
	(2328, 2369, 17703, 'TE-0443500015-00', '2023-07-13 12:32:01'),
	(2330, 2371, 17246, 'TE-0433300018-02', '2021-01-28 11:16:19'),
	(2336, 2377, 20470, 'PY-RD18005', '2021-01-28 11:16:20'),
	(2337, 2378, 15942, 'PEN-KM463330', '2021-01-28 11:16:19'),
	(2338, 2379, 15940, 'PEN-KM463016', '2021-01-28 11:16:19'),
	(2339, 2380, 15941, 'PEN-KM463119', '2021-01-28 11:16:19'),
	(2340, 2381, 15939, 'PEN-KM463930', '2021-01-28 11:16:19'),
	(2341, 2382, 15937, 'PEN-KM463616', '2021-01-28 11:16:19'),
	(2342, 2383, 15938, 'PEN-KM463719', '2021-01-28 11:16:19'),
	(2343, 2384, 13076, 'IX-0001012014', '2023-02-24 09:15:07'),
	(2708, 979, 19452, 'T-T055908', '2020-11-10 12:14:41'),
	(2709, 2452, 20664, 'IH-5379668014', '2020-11-10 12:14:41'),
	(2710, 862, 20663, 'IH-5379561020', '2020-11-10 12:14:41'),
	(2711, 2441, 20673, 'IH-5379594020', '2020-11-10 12:14:41'),
	(3342, 3505, 21317, 'MT-61060', '2021-02-09 11:48:23'),
	(3344, 3507, 21322, 'MT-69140', '2021-03-05 16:46:35'),
	(3774, 3937, 21325, 'MT-41701', '2021-02-09 11:48:23'),
	(3776, 3939, 21328, 'MT-21130', '2021-02-09 11:48:23'),
	(3779, 3942, 21334, 'MT-21136', '2021-02-09 11:48:23'),
	(3782, 3945, 21326, 'MT-25170', '2024-05-16 00:34:58'),
	(3783, 3946, 21331, 'MT-21093', '2021-02-09 11:48:23'),
	(4015, 5382, 20192, 'BE-70000012', '2024-04-10 13:08:18'),
	(4019, 5219, 19577, 'DC-000701', '2022-12-20 12:33:52'),
	(4020, 4690, 14218, 'SA-10620701', '2023-02-01 13:45:04'),
	(4021, 4691, 19726, 'GE-670701', '2023-08-25 13:35:38'),
	(4022, 4695, 245, 'PY-IC200116', '2023-07-14 13:32:58'),
	(4023, 4624, 20962, 'EAG-345000000', '2022-11-25 17:25:57'),
	(4024, 4713, 17293, 'WK-500190', '2022-11-07 10:06:50'),
	(4026, 5232, 20635, 'FL-11005', '2022-10-20 10:36:24'),
	(4027, 5233, 20632, 'FL-11001', '2023-01-03 16:47:29'),
	(4028, 5235, 20633, 'FL-11002', '2022-10-20 10:37:09'),
	(4029, 5236, 20637, 'FL-11007', '2022-10-20 10:37:24'),
	(4030, 5237, 20638, 'FL-11006', '2022-10-20 10:37:33'),
	(4031, 5238, 20634, 'FL-11004', '2022-10-20 10:37:53'),
	(4032, 4721, 5998, 'SCALP-005924', '2023-02-20 13:54:27'),
	(4033, 4727, 19730, 'GE-670711', '2023-08-25 13:41:31'),
	(4034, 4730, 20735, 'WK-400890', '2022-11-03 13:04:43'),
	(4035, 4733, 20454, 'GE-00002016', '2023-03-07 14:48:59'),
	(4036, 4738, 17332, 'SA-40000500', '2022-11-17 10:50:52'),
	(4037, 4753, 19493, 'WK-400130', '2022-11-03 12:58:42'),
	(4038, 5299, 20259, 'ES-6550004', '2022-10-18 12:44:59'),
	(4039, 5358, 19741, 'DC-000709', '2022-12-20 13:20:34'),
	(4040, 4765, 17292, 'WK-500340', '2022-11-07 10:11:33'),
	(4041, 4766, 20955, 'GE-00001016', '2023-08-26 10:30:40'),
	(4043, 5366, 22051, 'ES-0001245', '2022-10-18 13:29:22'),
	(4044, 5367, 22049, 'ES-0001252', '2022-10-18 13:30:14'),
	(4046, 4633, 19035, 'GE-60001216', '2021-03-05 16:52:33'),
	(4048, 5383, 10350, 'PRE-150016', '2023-09-14 13:31:16'),
	(4049, 5149, 21746, 'TA-S91001840', '2021-04-12 12:52:26'),
	(4051, 4648, 5678, 'RH-APU3430050', '2023-09-04 11:57:53'),
	(4053, 5214, 21941, 'TA-S91004040', '2021-04-12 12:52:26'),
	(4056, 5386, 10353, 'PRE-140016', '2023-09-14 13:31:16'),
	(4057, 5216, 19742, 'DC-000710', '2021-04-12 12:56:14'),
	(4058, 5217, 19749, 'DC-000744', '2021-04-12 12:56:14'),
	(4059, 5218, 19567, 'DC-000702', '2021-04-12 12:56:14'),
	(4060, 4692, 19729, 'GE-670706', '2023-08-25 13:40:32'),
	(4062, 5223, 19745, 'DC-000745', '2021-04-12 12:56:14'),
	(4063, 5229, 19607, 'DC-000707', '2021-04-12 12:56:14'),
	(4064, 5234, 20636, 'FL-11008', '2021-04-12 12:52:26'),
	(4065, 4720, 19727, 'GE-670717', '2023-08-25 13:42:05'),
	(4066, 4722, 1617, 'RH-PP5791', '2023-09-04 11:56:35'),
	(4067, 5239, 21754, 'TA-X91006223', '2021-04-12 12:52:26'),
	(4068, 5240, 21755, 'TA-X91006123', '2021-04-12 12:52:26'),
	(4069, 5241, 21772, 'TA-X91002501', '2023-09-25 09:21:57'),
	(4070, 5244, 21773, 'TA-X91003910', '2021-04-12 12:52:26'),
	(4071, 5248, 21942, 'TA-S91004540', '2021-04-12 12:52:26'),
	(4072, 5249, 21756, 'TA-X91006323', '2024-05-28 12:59:03'),
	(4073, 5250, 21752, 'TA-X91006423', '2024-05-28 12:59:26'),
	(4074, 5251, 22050, 'ES-000B100', '2021-04-12 12:52:26'),
	(4075, 4737, 20991, 'DIS-04017J759', '2023-11-14 12:28:59'),
	(4076, 4740, 16878, 'AB-C2003', '2021-03-05 16:52:33'),
	(4077, 4741, 18463, 'AB-C2002', '2021-03-05 16:52:33'),
	(4078, 4742, 2342, 'AB-C2005', '2024-06-16 21:28:32'),
	(4079, 4743, 17508, 'AB-C2026', '2021-03-05 16:52:33'),
	(4080, 5264, 19573, 'DC-000705', '2024-07-10 08:31:43'),
	(4081, 4744, 6000, 'SCALP-007624', '2024-02-24 12:36:06'),
	(4082, 4745, 14913, 'SCALP-007312', '2024-02-24 12:36:42'),
	(4083, 5267, 19743, 'DC-000713', '2021-04-12 12:56:14'),
	(4084, 5268, 19566, 'DC-000706', '2021-04-12 12:56:14'),
	(4085, 5269, 19608, 'DC-000708', '2021-04-12 12:56:14'),
	(4086, 5270, 19751, 'DC-000755', '2021-04-12 12:56:14'),
	(4088, 5271, 21771, 'TA-X91003810', '2024-05-28 12:24:49'),
	(4089, 4965, 22228, 'TA-093802011', '2024-05-14 12:34:19'),
	(4090, 4966, 22227, 'TA-090802001', '2021-03-24 15:38:15'),
	(4093, 4749, 15111, 'SA-56414209', '2021-03-05 16:52:33'),
	(4094, 4750, 17290, 'WK-500220', '2021-03-09 16:57:31'),
	(4095, 4754, 11859, 'RH-APU190678', '2023-09-04 11:59:27'),
	(4096, 5282, 21751, 'TA-X91006523', '2024-05-28 13:01:52'),
	(4098, 5354, 19746, 'DC-000740', '2021-04-12 12:56:14'),
	(4099, 5359, 19750, 'DC-000753', '2021-04-12 12:56:14'),
	(4100, 5360, 19747, 'DC-000741', '2021-04-12 12:56:14'),
	(4101, 5361, 19744, 'DC-000712', '2021-04-12 12:56:14'),
	(4102, 5362, 21768, 'TA-X91005010', '2024-05-28 12:37:09'),
	(4103, 5368, 19748, 'DC-000743', '2021-04-12 12:56:14'),
	(4104, 4777, 12435, 'DIS-999003', '2023-05-08 12:13:03'),
	(4105, 4739, 17279, 'WK-400060', '2023-06-13 17:27:05'),
	(4106, 5424, 21021, 'PE-0009695', '2023-08-31 09:13:23'),
	(4107, 2107, 19627, 'PE-0013291', '2023-08-31 09:00:13'),
	(4108, 2344, 14939, 'PE-0007235', '2023-08-31 09:46:34'),
	(4113, 2205, 20100, 'PE-00013029', '2023-09-01 12:46:40'),
	(4114, 2238, 20935, 'PE-0013128', '2023-08-30 12:49:44'),
	(4116, 2207, 20785, 'PE-0008030', '2023-08-30 11:58:33'),
	(4117, 2216, 18462, 'PE-0013087', '2023-10-23 17:33:22'),
	(4119, 2250, 19626, 'PE-0013290', '2023-11-15 12:28:29'),
	(4120, 2320, 21022, 'PE-0013035', '2023-08-30 12:59:07'),
	(4121, 2328, 14940, 'PE-0007321', '2023-08-30 09:27:51'),
	(4122, 4187, 17810, 'PE-0013116', '2023-08-31 09:55:27'),
	(4128, 5430, 23048, 'BLA-06102615', '2023-09-20 15:20:24'),
	(4130, 5432, 14250, '1-94660122', '2023-09-20 15:20:24'),
	(4132, 5434, 7181, '1-74560013', '2023-09-20 15:20:24'),
	(4136, 5438, 10937, '1-81540014', '2023-09-20 15:20:24'),
	(4144, 5446, 10950, '1-80040014', '2023-09-20 15:20:24'),
	(4145, 5447, 20968, '1-PYP503900122', '2023-09-20 15:20:24'),
	(4153, 5455, 11153, '1-PYP502400134', '2023-09-20 15:20:24'),
	(4154, 5456, 18424, '1-T822010014', '2023-09-28 09:41:28'),
	(4155, 5457, 18427, '1-T823010013', '2023-09-20 15:20:24'),
	(4164, 5466, 11018, '1-77138214', '2023-09-20 15:20:24'),
	(4166, 5468, 11037, '1-76560014', '2023-09-20 15:20:24'),
	(4172, 5474, 23056, 'BLA-01220451', '2023-09-20 15:20:24'),
	(4187, 5489, 24469, '3-T830710114', '2023-09-20 15:20:24'),
	(4190, 5492, 14504, '1-PYP500410022', '2023-09-20 15:20:24'),
	(4192, 5494, 18086, '1-PY504000114', '2023-09-20 15:20:24'),
	(4197, 5499, 18109, '1-PY504200114', '2023-09-20 15:20:24'),
	(4200, 5502, 18096, '1-PY504100114', '2023-09-20 15:20:24'),
	(4215, 5517, 23115, 'BLA-01502908', '2023-09-20 15:20:24'),
	(4217, 5519, 7197, '1-73460522', '2023-09-20 15:20:24'),
	(4222, 5524, 1155, '1-80449114', '2023-10-09 13:19:33'),
	(4224, 5526, 20184, 'BE-70396114', '2023-10-09 13:19:33'),
	(4239, 4632, 10921, 'SA-40000339', '2022-11-03 09:58:55'),
	(4240, 5536, 15780, 'RH-1BL04402809', '2022-11-03 08:37:42'),
	(4257, 5547, 20366, 'MTN-EX0149010', '2022-11-03 09:09:54'),
	(4259, 5549, 20363, 'MTN-EX0143001', '2022-11-03 09:10:01'),
	(4260, 5550, 20934, 'PE-0013127', '2023-09-13 08:59:57'),
	(4261, 5551, 22646, 'RH-R2170222', '2023-08-30 08:49:29'),
	(4404, 5694, 20284, 'GE-60001224', '2021-03-05 16:52:33'),
	(4412, 5702, 16994, 'MTN-940148317', '2023-09-12 14:06:02'),
	(4419, 5709, 22244, 'AL-533881P', '2021-04-12 12:52:26'),
	(4420, 5710, 17553, 'WK-CG100160', '2021-03-05 16:52:33'),
	(4423, 5713, 17554, 'WK-CG100150', '2021-03-05 16:52:33'),
	(4426, 5716, 7400, 'RH-APC72000', '2024-02-01 18:35:18'),
	(4461, 5751, 1300, 'IH-1001508', '2023-09-14 13:34:34'),
	(4462, 5752, 15367, 'MTN-EX014H8023', '2023-09-13 08:58:04'),
	(4471, 5761, 17523, 'WK-CG100130', '2021-03-05 16:52:33'),
	(4473, 5763, 21025, 'DIS-400101710', '2021-03-05 16:52:33'),
	(4474, 5764, 22062, 'DIS-400101711', '2021-03-05 16:52:33'),
	(4495, 5785, 18111, '1-PY504200132', '2023-09-20 15:20:24'),
	(4499, 5789, 14551, 'AB-F3100', '2024-01-02 09:53:34'),
	(4500, 5790, 14550, 'AB-F3000', '2023-06-30 12:24:09'),
	(4504, 5794, 17695, 'TE-0443500018-00', '2023-05-31 09:21:53');

-- Volcando estructura para tabla conectoraf_rubio.cliente_email
CREATE TABLE IF NOT EXISTS `cliente_email` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `cliente_af` varchar(45) COLLATE latin1_spanish_ci DEFAULT NULL,
  `email` varchar(250) COLLATE latin1_spanish_ci DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_spanish_ci;

-- Volcando datos para la tabla conectoraf_rubio.cliente_email: ~0 rows (aproximadamente)
DELETE FROM `cliente_email`;

-- Volcando estructura para tabla conectoraf_rubio.configuracion
CREATE TABLE IF NOT EXISTS `configuracion` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `campo` varchar(100) NOT NULL,
  `valor` varchar(100) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

-- Volcando datos para la tabla conectoraf_rubio.configuracion: ~0 rows (aproximadamente)
DELETE FROM `configuracion`;

-- Volcando estructura para tabla conectoraf_rubio.estados_cabecera
CREATE TABLE IF NOT EXISTS `estados_cabecera` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `estado` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
  `des` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
  `id_catalogo` int(11) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

-- Volcando datos para la tabla conectoraf_rubio.estados_cabecera: ~4 rows (aproximadamente)
DELETE FROM `estados_cabecera`;
INSERT INTO `estados_cabecera` (`id`, `estado`, `des`, `id_catalogo`) VALUES
	(2, 'P', 'Pendiente', 2),
	(3, 'S', 'Servido', 5),
	(4, 'A', 'Anulado', 6),
	(5, 'R', 'Retenido', 10);

-- Volcando estructura para tabla conectoraf_rubio.estados_linea
CREATE TABLE IF NOT EXISTS `estados_linea` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `estado` varchar(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,
  `des` varchar(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci NOT NULL,
  `id_catalogo` int(11) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=latin1 COLLATE=latin1_bin;

-- Volcando datos para la tabla conectoraf_rubio.estados_linea: ~5 rows (aproximadamente)
DELETE FROM `estados_linea`;
INSERT INTO `estados_linea` (`id`, `estado`, `des`, `id_catalogo`) VALUES
	(1, 'PP', 'No hay stock', 1),
	(2, 'p', 'Generado pedido de compra', 2),
	(3, 'x', 'Realizado albarán de compra', 3),
	(4, 'AA', 'Hay stock', 4),
	(5, 'a', 'Generado albarán de venta', 5);

-- Volcando estructura para tabla conectoraf_rubio.estado_relacion
CREATE TABLE IF NOT EXISTS `estado_relacion` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `nombre` varchar(45) DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8;

-- Volcando datos para la tabla conectoraf_rubio.estado_relacion: ~2 rows (aproximadamente)
DELETE FROM `estado_relacion`;
INSERT INTO `estado_relacion` (`id`, `nombre`) VALUES
	(1, 'Pediente Envio'),
	(2, 'Actualizado');

-- Volcando estructura para tabla conectoraf_rubio.fabricante_web
CREATE TABLE IF NOT EXISTS `fabricante_web` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `id_fabricante_web` int(11) NOT NULL,
  `fabricante_af` varchar(45) COLLATE utf8_unicode_ci NOT NULL,
  `fecha_actualizacion` datetime DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

-- Volcando datos para la tabla conectoraf_rubio.fabricante_web: ~0 rows (aproximadamente)
DELETE FROM `fabricante_web`;

-- Volcando estructura para tabla conectoraf_rubio.proveedor_web
CREATE TABLE IF NOT EXISTS `proveedor_web` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `id_proveedor_web` int(11) NOT NULL,
  `proveedor_af` varchar(45) COLLATE utf8_unicode_ci NOT NULL,
  `fecha_actualizacion` datetime DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

-- Volcando datos para la tabla conectoraf_rubio.proveedor_web: ~0 rows (aproximadamente)
DELETE FROM `proveedor_web`;

-- Volcando estructura para tabla conectoraf_rubio.relacion_cabecera
CREATE TABLE IF NOT EXISTS `relacion_cabecera` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `id_catalogo` int(11) NOT NULL,
  `ejercicio` int(11) NOT NULL,
  `serie` int(11) NOT NULL,
  `documento` int(11) NOT NULL,
  `id_tienda` int(11) DEFAULT NULL,
  `tipo_documento_id` int(11) DEFAULT NULL,
  `ejercicioA` int(11) DEFAULT NULL,
  `serieA` int(11) DEFAULT NULL,
  `documentoA` int(11) DEFAULT NULL,
  `ejercicioF` int(11) DEFAULT NULL,
  `serieF` int(11) DEFAULT NULL,
  `documentoF` int(11) DEFAULT NULL,
  `estado` varchar(45) DEFAULT NULL,
  PRIMARY KEY (`id`),
  KEY `fk_relacion_cabecera_tipo_documento_idx` (`tipo_documento_id`),
  CONSTRAINT `fk_relacion_cabecera_tipo_documento` FOREIGN KEY (`tipo_documento_id`) REFERENCES `tipo_documento` (`id`) ON DELETE NO ACTION ON UPDATE NO ACTION
) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8;

-- Volcando datos para la tabla conectoraf_rubio.relacion_cabecera: ~3 rows (aproximadamente)
DELETE FROM `relacion_cabecera`;
INSERT INTO `relacion_cabecera` (`id`, `id_catalogo`, `ejercicio`, `serie`, `documento`, `id_tienda`, `tipo_documento_id`, `ejercicioA`, `serieA`, `documentoA`, `ejercicioF`, `serieF`, `documentoF`, `estado`) VALUES
	(1, 266, 2023, 19, 1, NULL, 1, NULL, NULL, NULL, 2023, 19, 1, 'S'),
	(2, 267, 2023, 19, 2, NULL, 1, NULL, NULL, NULL, NULL, NULL, NULL, 'A'),
	(8, 274, 2023, 19, 8, NULL, 1, NULL, NULL, NULL, 2023, 19, 2, 'S'),
	(9, 276, 2024, 19, 1, NULL, 1, NULL, NULL, NULL, NULL, NULL, NULL, 'P');

-- Volcando estructura para tabla conectoraf_rubio.relacion_lineas
CREATE TABLE IF NOT EXISTS `relacion_lineas` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `relacion_cabecera_id` int(11) DEFAULT NULL,
  `id_linea` int(11) NOT NULL,
  `linea` int(11) DEFAULT NULL,
  PRIMARY KEY (`id`),
  KEY `fk_relacion_lineas_relacion_cabecera1_idx` (`relacion_cabecera_id`),
  CONSTRAINT `FK_EA3059FB72BAA0ED` FOREIGN KEY (`relacion_cabecera_id`) REFERENCES `relacion_cabecera` (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=16 DEFAULT CHARSET=utf8;

-- Volcando datos para la tabla conectoraf_rubio.relacion_lineas: ~9 rows (aproximadamente)
DELETE FROM `relacion_lineas`;
INSERT INTO `relacion_lineas` (`id`, `relacion_cabecera_id`, `id_linea`, `linea`) VALUES
	(1, 1, 300, 2),
	(2, 2, 301, 2),
	(8, 8, 308, 2),
	(9, 8, 309, 4),
	(10, 8, 310, 6),
	(11, 8, 311, 8),
	(12, 8, 312, 10),
	(13, 8, 313, 12),
	(14, 8, 314, 14),
	(15, 9, 316, 2);

-- Volcando estructura para tabla conectoraf_rubio.relacion_provincia
CREATE TABLE IF NOT EXISTS `relacion_provincia` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `provincia_af` varchar(10) DEFAULT NULL,
  `provincia_web` int(11) DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=53 DEFAULT CHARSET=utf8;

-- Volcando datos para la tabla conectoraf_rubio.relacion_provincia: ~52 rows (aproximadamente)
DELETE FROM `relacion_provincia`;
INSERT INTO `relacion_provincia` (`id`, `provincia_af`, `provincia_web`) VALUES
	(1, '01', 326),
	(2, '02', 327),
	(3, '03', 328),
	(4, '04', 329),
	(5, '05', 331),
	(6, '06', 332),
	(7, '07', 333),
	(8, '08', 334),
	(9, '09', 335),
	(10, '10', 336),
	(11, '11', 337),
	(12, '12', 339),
	(13, '13', 340),
	(14, '14', 341),
	(15, '15', 325),
	(16, '16', 342),
	(17, '17', 343),
	(18, '18', 344),
	(19, '19', 345),
	(20, '20', 346),
	(21, '21', 347),
	(22, '22', 348),
	(23, '23', 349),
	(24, '24', 352),
	(25, '25', 353),
	(26, '26', 350),
	(27, '27', 354),
	(28, '28', 355),
	(29, '29', 356),
	(30, '30', 357),
	(31, '31', 358),
	(32, '32', 359),
	(33, '33', 330),
	(34, '34', 360),
	(35, '35', 351),
	(36, '36', 361),
	(37, '37', 362),
	(38, '38', 363),
	(39, '39', 338),
	(40, '40', 364),
	(41, '41', 365),
	(42, '42', 366),
	(43, '43', 367),
	(44, '44', 368),
	(45, '45', 369),
	(46, '46', 370),
	(47, '47', 371),
	(48, '48', 372),
	(49, '49', 373),
	(50, '50', 374),
	(51, '51', 375),
	(52, '52', 376);

-- Volcando estructura para tabla conectoraf_rubio.tipo_accion
CREATE TABLE IF NOT EXISTS `tipo_accion` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `nombre` varchar(45) DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8;

-- Volcando datos para la tabla conectoraf_rubio.tipo_accion: ~3 rows (aproximadamente)
DELETE FROM `tipo_accion`;
INSERT INTO `tipo_accion` (`id`, `nombre`) VALUES
	(1, 'Alta'),
	(2, 'Baja'),
	(3, 'Modificacion');

-- Volcando estructura para tabla conectoraf_rubio.tipo_documento
CREATE TABLE IF NOT EXISTS `tipo_documento` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `nombre` varchar(150) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8;

-- Volcando datos para la tabla conectoraf_rubio.tipo_documento: ~2 rows (aproximadamente)
DELETE FROM `tipo_documento`;
INSERT INTO `tipo_documento` (`id`, `nombre`) VALUES
	(1, 'Pedido'),
	(2, 'Presupuesto');

