 --
 
 CREATE TABLE `acessante` (
-  `user` varchar(10) NOT NULL,
+  `user` varchar(10) CHARACTER SET utf8 NOT NULL,
   `name` varchar(20) NOT NULL,
   `lastname` varchar(30) NOT NULL,
   `address` varchar(30) NOT NULL,

-- https://www.phpmyadmin.net/
--
-- Host: 127.0.0.1
-- Generation Time: 31-Maio-2017 às 01:32
-- Versão do servidor: 10.1.22-MariaDB
-- PHP Version: 7.1.4


--
ALTER TABLE `usuario`
  ADD PRIMARY KEY (`user`);

--
-- Constraints for dumped tables
--

--
-- Limitadores para a tabela `avaliacao`
--
ALTER TABLE `avaliacao`
  ADD CONSTRAINT `avaliacao_id_rep` FOREIGN KEY (`id_rep`) REFERENCES `republica` (`id`) ON DELETE NO ACTION ON UPDATE CASCADE,
  ADD CONSTRAINT `avaliacao_usuario_id` FOREIGN KEY (`user_id`) REFERENCES `usuario` (`user`) ON DELETE NO ACTION ON UPDATE CASCADE;

--
-- Limitadores para a tabela `gastos`
--
ALTER TABLE `gastos`
  ADD CONSTRAINT `gastos_id_rep` FOREIGN KEY (`id_rep`) REFERENCES `republica` (`id`) ON DELETE NO ACTION ON UPDATE NO ACTION;
COMMIT;

/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
