   `id_area` int(11) NOT NULL,
   `id_subarea` int(11) NOT NULL,
   `id_user` int(11) NOT NULL,
-  `active` int(1) NOT NULL DEFAULT '1',
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `id_event` (`id_event`),
-  KEY `id_area` (`id_area`,`id_subarea`),
-  KEY `id_user` (`id_user`)
+  `active` int(1) NOT NULL DEFAULT '1'
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;
 
 -- --------------------------------------------------------
 
 --
--- Estructura de tabla para la tabla `STATUS_COMMENT`
---
-
+-- Table structure for table `STATUS_COMMENT`
+--
+
+DROP TABLE IF EXISTS `STATUS_COMMENT`;
 CREATE TABLE IF NOT EXISTS `STATUS_COMMENT` (
   `id` int(11) NOT NULL,
-  `description` varchar(30) NOT NULL,
-  PRIMARY KEY (`id`)
+  `description` varchar(30) NOT NULL
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
 
 --
--- Volcado de datos para la tabla `STATUS_COMMENT`
+-- Dumping data for table `STATUS_COMMENT`
 --
 
 INSERT INTO `STATUS_COMMENT` (`id`, `description`) VALUES
-  (1, 'Pendiente Aprobación'),
-  (2, 'Aprobado'),
-  (3, 'Denunciado'),
-  (4, 'Eliminado');
-
--- --------------------------------------------------------
-
---
--- Estructura de tabla para la tabla `SUBAREA`
---
-
+(1, 'Pendiente Aprobación'),
+(2, 'Aprobado'),
+(3, 'Denunciado'),
+(4, 'Eliminado');
+
+-- --------------------------------------------------------
+
+--
+-- Table structure for table `SUBAREA`
+--
+
+DROP TABLE IF EXISTS `SUBAREA`;
 CREATE TABLE IF NOT EXISTS `SUBAREA` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
+`id` int(11) NOT NULL,
   `description` varchar(100) CHARACTER SET utf8 NOT NULL,
   `id_area` int(11) NOT NULL,
-  PRIMARY KEY (`id`)
+  `active` int(1) NOT NULL
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 AUTO_INCREMENT=1 ;
 
 -- --------------------------------------------------------
 
 --
--- Estructura de tabla para la tabla `USER`
---
-
+-- Table structure for table `USER`
+--
+
+DROP TABLE IF EXISTS `USER`;
 CREATE TABLE IF NOT EXISTS `USER` (
-  `id` int(11) NOT NULL AUTO_INCREMENT,
+`id` int(11) NOT NULL,
   `name` varchar(60) NOT NULL,
   `email` varchar(30) NOT NULL,
   `password` varchar(30) NOT NULL,
   `id_user_type` int(11) NOT NULL,
-  `active` int(1) NOT NULL DEFAULT '1',
-  PRIMARY KEY (`id`),
-  UNIQUE KEY `EMAIL` (`email`),
-  KEY `id_user_type` (`id_user_type`)
+  `active` int(1) NOT NULL DEFAULT '1'
 ) ENGINE=InnoDB  DEFAULT CHARSET=utf8 AUTO_INCREMENT=41 ;
 
 --
--- Volcado de datos para la tabla `USER`
+-- Dumping data for table `USER`
 --
 
 INSERT INTO `USER` (`id`, `name`, `email`, `password`, `id_user_type`, `active`) VALUES
-  (1, 'Martin', 'mmaestri@gmail.com', '123456', 2, 1),
-  (19, 'usuario@mail.com', 'usuario@mail.com', '123456', 2, 1),
-  (39, 'user@mail.com', 'user@mail.com', '123456', 2, 1),
-  (40, 'otro@mail.com', 'otro@mail.com', '123456', 2, 1);
-
--- --------------------------------------------------------
-
---
--- Estructura de tabla para la tabla `USER_TYPE`
---
-
+(1, 'Martin', 'mmaestri@gmail.com', '123456', 2, 1),
+(19, 'usuario@mail.com', 'usuario@mail.com', '123456', 2, 1),
+(39, 'user@mail.com', 'user@mail.com', '123456', 2, 1),
+(40, 'otro@mail.com', 'otro@mail.com', '123456', 2, 1);
+
+-- --------------------------------------------------------
+
+--
+-- Table structure for table `USER_TYPE`
+--
+
+DROP TABLE IF EXISTS `USER_TYPE`;
 CREATE TABLE IF NOT EXISTS `USER_TYPE` (
   `id` int(11) NOT NULL,
-  `description` varchar(50) NOT NULL,
-  PRIMARY KEY (`id`)
+  `description` varchar(50) NOT NULL
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
 
 --
--- Volcado de datos para la tabla `USER_TYPE`
+-- Dumping data for table `USER_TYPE`
 --
 
 INSERT INTO `USER_TYPE` (`id`, `description`) VALUES
-  (1, 'Administrador'),
-  (2, 'Publicador'),
-  (3, 'Usuario General');
-
+(1, 'Administrador'),
+(2, 'Publicador'),
+(3, 'Usuario General');
+
+--
+-- Indexes for dumped tables
+--
+
+--
+-- Indexes for table `ALERT`
+--
+ALTER TABLE `ALERT`
+ ADD PRIMARY KEY (`id`), ADD KEY `id_user` (`id_user`,`id_subarea`);
+
+--
+-- Indexes for table `AREA`
+--
+ALTER TABLE `AREA`
+ ADD PRIMARY KEY (`id`);
+
+--
+-- Indexes for table `COMMENT`
+--
+ALTER TABLE `COMMENT`
+ ADD PRIMARY KEY (`id`);
+
+--
+-- Indexes for table `EVENT`
+--
+ALTER TABLE `EVENT`
+ ADD PRIMARY KEY (`Id`), ADD UNIQUE KEY `Id_2` (`Id`), ADD UNIQUE KEY `IdEvento` (`IdEvento`), ADD KEY `Id` (`Id`), ADD KEY `IdEvento_2` (`IdEvento`);
+
+--
+-- Indexes for table `EVENT-not-used`
+--
+ALTER TABLE `EVENT-not-used`
+ ADD PRIMARY KEY (`id`), ADD UNIQUE KEY `id_event` (`id_event`), ADD KEY `id_area` (`id_area`,`id_subarea`), ADD KEY `id_user` (`id_user`);
+
+--
+-- Indexes for table `STATUS_COMMENT`
+--
+ALTER TABLE `STATUS_COMMENT`
+ ADD PRIMARY KEY (`id`);
+
+--
+-- Indexes for table `SUBAREA`
+--
+ALTER TABLE `SUBAREA`
+ ADD PRIMARY KEY (`id`);
+
+--
+-- Indexes for table `USER`
+--
+ALTER TABLE `USER`
+ ADD PRIMARY KEY (`id`), ADD UNIQUE KEY `EMAIL` (`email`), ADD KEY `id_user_type` (`id_user_type`);
+
+--
+-- Indexes for table `USER_TYPE`
+--
+ALTER TABLE `USER_TYPE`
+ ADD PRIMARY KEY (`id`);
+
+--
+-- AUTO_INCREMENT for dumped tables
+--
+
+--
+-- AUTO_INCREMENT for table `ALERT`
+--
+ALTER TABLE `ALERT`
+MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
+--
+-- AUTO_INCREMENT for table `AREA`
+--
+ALTER TABLE `AREA`
+MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
+--
+-- AUTO_INCREMENT for table `COMMENT`
+--
+ALTER TABLE `COMMENT`
+MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
+--
+-- AUTO_INCREMENT for table `EVENT`
+--
+ALTER TABLE `EVENT`
+MODIFY `Id` int(11) NOT NULL AUTO_INCREMENT;
+--
+-- AUTO_INCREMENT for table `EVENT-not-used`
+--
+ALTER TABLE `EVENT-not-used`
+MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
+--
+-- AUTO_INCREMENT for table `SUBAREA`
+--
+ALTER TABLE `SUBAREA`
+MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
+--
+-- AUTO_INCREMENT for table `USER`
+--
+ALTER TABLE `USER`
+MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=41;
 /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
 /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
 /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;

/*!40101 SET NAMES utf8 */;

--
-- Base de datos: `u185673925_event`
--

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

--
-- Estructura de tabla para la tabla `ALERT`
--

CREATE TABLE IF NOT EXISTS `ALERT` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `id_user` int(11) NOT NULL,
  `id_area` int(11) DEFAULT NULL,
  `id_subarea` int(11) DEFAULT NULL,
  `keyword` varchar(100) NOT NULL,
  `active` int(1) NOT NULL DEFAULT '1',
  PRIMARY KEY (`id`),
  KEY `id_user` (`id_user`,`id_subarea`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;

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

--
-- Estructura de tabla para la tabla `AREA`
--

CREATE TABLE IF NOT EXISTS `AREA` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `description` varchar(300) CHARACTER SET utf8 NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 AUTO_INCREMENT=1 ;

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

--
-- Estructura de tabla para la tabla `COMMENT`
--

CREATE TABLE IF NOT EXISTS `COMMENT` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `text` varchar(300) NOT NULL,
  `id_status_comment` int(11) NOT NULL DEFAULT '1',
  `id_event` int(11) NOT NULL,
  `stars` int(1) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;

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

--
-- Estructura de tabla para la tabla `EVENT`
--

CREATE TABLE IF NOT EXISTS `EVENT` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `id_event` int(11) NOT NULL,
  `name` varchar(100) NOT NULL,
  `description` varchar(3000) NOT NULL,

-- phpMyAdmin SQL Dump
-- version 4.2.7.1
-- http://www.phpmyadmin.net
--
-- Host: localhost
-- Generation Time: Nov 02, 2014 at 10:39 PM
-- Server version: 5.6.20
-- PHP Version: 5.5.15

SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
