db0.sql 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. -- MySQL dump 10.13 Distrib 5.5.43, for debian-linux-gnu (x86_64)
  2. --
  3. -- Host: localhost Database: goweb_social_network
  4. -- ------------------------------------------------------
  5. -- Server version 5.5.43-0ubuntu0.12.04.1-log
  6. /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
  7. /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
  8. /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
  9. /*!40101 SET NAMES utf8 */;
  10. /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
  11. /*!40103 SET TIME_ZONE='+00:00' */;
  12. /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
  13. /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
  14. /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
  15. /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
  16. --
  17. -- Table structure for table `users`
  18. --
  19. DROP TABLE IF EXISTS `users`;
  20. /*!40101 SET @saved_cs_client = @@character_set_client */;
  21. /*!40101 SET character_set_client = utf8 */;
  22. CREATE TABLE `users` (
  23. `user_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  24. `user_nickname` varchar(32) NOT NULL,
  25. `user_first` varchar(32) NOT NULL,
  26. `user_last` varchar(32) NOT NULL,
  27. `user_email` varchar(128) NOT NULL,
  28. PRIMARY KEY (`user_id`),
  29. UNIQUE KEY `user_nickname` (`user_nickname`),
  30. UNIQUE KEY `user_email` (`user_email`)
  31. ) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8mb4;
  32. /*!40101 SET character_set_client = @saved_cs_client */;
  33. --
  34. -- Table structure for table `users_relationships`
  35. --
  36. DROP TABLE IF EXISTS `users_relationships`;
  37. /*!40101 SET @saved_cs_client = @@character_set_client */;
  38. /*!40101 SET character_set_client = utf8 */;
  39. CREATE TABLE `users_relationships` (
  40. `users_relationship_id` int(13) NOT NULL,
  41. `from_user_id` int(10) NOT NULL,
  42. `to_user_id` int(11) NOT NULL,
  43. `users_relationship_type` varchar(10) NOT NULL,
  44. `users_relationship_timestamp` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  45. PRIMARY KEY (`users_relationship_id`),
  46. KEY `from_user_id` (`from_user_id`),
  47. KEY `to_user_id` (`to_user_id`),
  48. KEY `from_user_id_to_user_id` (`from_user_id`,`to_user_id`),
  49. KEY `from_user_id_to_user_id_users_relationship_type` (`from_user_id`,`to_user_id`,`users_relationship_type`)
  50. ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
  51. /*!40101 SET character_set_client = @saved_cs_client */;
  52. /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
  53. /*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
  54. /*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
  55. /*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
  56. /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
  57. /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
  58. /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
  59. /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
  60. -- Dump completed on 2015-07-01 17:04:48