Skip to content

Instantly share code, notes, and snippets.

@andygrunwald
Created March 23, 2014 16:51
Show Gist options
  • Save andygrunwald/9725917 to your computer and use it in GitHub Desktop.
Save andygrunwald/9725917 to your computer and use it in GitHub Desktop.
CVSAnaly PR #60 pr60-sql-dump
-- MySQL dump 10.13 Distrib 5.6.16, for osx10.9 (x86_64)
--
-- Host: localhost Database: cvsanaly_after
-- ------------------------------------------------------
-- Server version 5.6.16
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
--
-- Temporary table structure for view `action_files`
--
DROP TABLE IF EXISTS `action_files`;
/*!50001 DROP VIEW IF EXISTS `action_files`*/;
SET @saved_cs_client = @@character_set_client;
SET character_set_client = utf8;
/*!50001 CREATE TABLE `action_files` (
`file_id` tinyint NOT NULL,
`action_id` tinyint NOT NULL,
`action_type` tinyint NOT NULL,
`commit_id` tinyint NOT NULL
) ENGINE=MyISAM */;
SET character_set_client = @saved_cs_client;
--
-- Table structure for table `actions`
--
DROP TABLE IF EXISTS `actions`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `actions` (
`id` int(11) NOT NULL DEFAULT '0',
`type` varchar(1) DEFAULT NULL,
`file_id` int(11) DEFAULT NULL,
`commit_id` int(11) DEFAULT NULL,
`branch_id` int(11) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `file_id` (`file_id`),
KEY `commit_id` (`commit_id`),
KEY `branch_id` (`branch_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `actions`
--
LOCK TABLES `actions` WRITE;
/*!40000 ALTER TABLE `actions` DISABLE KEYS */;
INSERT INTO `actions` VALUES (1,'A',2,1,1),(2,'A',3,1,1),(3,'A',5,1,1),(4,'V',3,2,1),(5,'A',7,3,1),(6,'D',3,4,1),(7,'V',5,4,1),(8,'A',9,5,1),(9,'A',12,6,1),(10,'V',2,7,1),(11,'M',2,8,1);
/*!40000 ALTER TABLE `actions` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Temporary table structure for view `actions_file_names`
--
DROP TABLE IF EXISTS `actions_file_names`;
/*!50001 DROP VIEW IF EXISTS `actions_file_names`*/;
SET @saved_cs_client = @@character_set_client;
SET character_set_client = utf8;
/*!50001 CREATE TABLE `actions_file_names` (
`id` tinyint NOT NULL,
`type` tinyint NOT NULL,
`file_id` tinyint NOT NULL,
`new_file_name` tinyint NOT NULL,
`commit_id` tinyint NOT NULL
) ENGINE=MyISAM */;
SET character_set_client = @saved_cs_client;
--
-- Table structure for table `branches`
--
DROP TABLE IF EXISTS `branches`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `branches` (
`id` int(11) NOT NULL,
`name` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `branches`
--
LOCK TABLES `branches` WRITE;
/*!40000 ALTER TABLE `branches` DISABLE KEYS */;
INSERT INTO `branches` VALUES (1,'master');
/*!40000 ALTER TABLE `branches` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `file_copies`
--
DROP TABLE IF EXISTS `file_copies`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `file_copies` (
`id` int(11) NOT NULL,
`to_id` int(11) DEFAULT NULL,
`from_id` int(11) DEFAULT NULL,
`from_commit_id` int(11) DEFAULT NULL,
`new_file_name` mediumtext,
`action_id` int(11) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `from_id` (`from_id`),
KEY `to_id` (`to_id`),
KEY `from_commit_id` (`from_commit_id`),
KEY `action_id` (`action_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `file_copies`
--
LOCK TABLES `file_copies` WRITE;
/*!40000 ALTER TABLE `file_copies` DISABLE KEYS */;
INSERT INTO `file_copies` VALUES (1,3,3,2,'something',4),(2,5,5,4,'something.renamed',7),(3,2,2,7,'otherthing.renamed',10);
/*!40000 ALTER TABLE `file_copies` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `file_links`
--
DROP TABLE IF EXISTS `file_links`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `file_links` (
`id` int(11) NOT NULL,
`parent_id` int(11) DEFAULT NULL,
`file_id` int(11) DEFAULT NULL,
`commit_id` int(11) DEFAULT NULL,
`file_path` varchar(4096) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `parent_id` (`parent_id`),
KEY `file_id` (`file_id`),
KEY `commit_id` (`commit_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `file_links`
--
LOCK TABLES `file_links` WRITE;
/*!40000 ALTER TABLE `file_links` DISABLE KEYS */;
INSERT INTO `file_links` VALUES (1,-1,1,1,'aaa'),(2,1,2,1,'aaa/otherthing'),(3,1,3,1,'aaa/something'),(4,-1,4,1,'bbb'),(5,4,5,1,'bbb/bthing'),(6,4,3,2,'bbb/something'),(7,4,6,3,'bbb/ccc'),(8,6,7,3,'bbb/ccc/yet_anotherthing'),(9,4,5,4,'bbb/something.renamed'),(10,-1,8,5,'ddd'),(11,8,9,5,'ddd/finalthing'),(12,-1,10,6,'eee'),(13,10,11,6,'eee/fff'),(14,11,12,6,'eee/fff/wildthing'),(15,1,2,7,'aaa/otherthing.renamed');
/*!40000 ALTER TABLE `file_links` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `file_types`
--
DROP TABLE IF EXISTS `file_types`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `file_types` (
`id` int(11) NOT NULL,
`file_id` int(11) DEFAULT NULL,
`type` mediumtext,
PRIMARY KEY (`id`),
KEY `file_id` (`file_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `file_types`
--
LOCK TABLES `file_types` WRITE;
/*!40000 ALTER TABLE `file_types` DISABLE KEYS */;
INSERT INTO `file_types` VALUES (1,2,'unknown'),(2,3,'unknown'),(3,5,'unknown'),(4,7,'unknown'),(5,9,'unknown'),(6,12,'unknown');
/*!40000 ALTER TABLE `file_types` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `files`
--
DROP TABLE IF EXISTS `files`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `files` (
`id` int(11) NOT NULL,
`file_name` varchar(255) DEFAULT NULL,
`repository_id` int(11) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `file_name` (`file_name`),
KEY `repository_id` (`repository_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `files`
--
LOCK TABLES `files` WRITE;
/*!40000 ALTER TABLE `files` DISABLE KEYS */;
INSERT INTO `files` VALUES (1,'aaa',1),(2,'otherthing',1),(3,'something',1),(4,'bbb',1),(5,'bthing',1),(6,'ccc',1),(7,'yet_anotherthing',1),(8,'ddd',1),(9,'finalthing',1),(10,'eee',1),(11,'fff',1),(12,'wildthing',1);
/*!40000 ALTER TABLE `files` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `metrics`
--
DROP TABLE IF EXISTS `metrics`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `metrics` (
`id` int(11) NOT NULL,
`file_id` int(11) DEFAULT NULL,
`commit_id` int(11) DEFAULT NULL,
`lang` tinytext,
`sloc` int(11) DEFAULT NULL,
`loc` int(11) DEFAULT NULL,
`ncomment` int(11) DEFAULT NULL,
`lcomment` int(11) DEFAULT NULL,
`lblank` int(11) DEFAULT NULL,
`nfunctions` int(11) DEFAULT NULL,
`mccabe_max` int(11) DEFAULT NULL,
`mccabe_min` int(11) DEFAULT NULL,
`mccabe_sum` int(11) DEFAULT NULL,
`mccabe_mean` int(11) DEFAULT NULL,
`mccabe_median` int(11) DEFAULT NULL,
`halstead_length` int(11) DEFAULT NULL,
`halstead_vol` int(11) DEFAULT NULL,
`halstead_level` double DEFAULT NULL,
`halstead_md` int(11) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `file_id` (`file_id`),
KEY `commit_id` (`commit_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `metrics`
--
LOCK TABLES `metrics` WRITE;
/*!40000 ALTER TABLE `metrics` DISABLE KEYS */;
INSERT INTO `metrics` VALUES (1,2,1,'unknown',0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(2,3,1,'unknown',0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(3,5,1,'unknown',0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(4,3,2,'unknown',0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(5,7,3,'unknown',0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(6,3,4,'unknown',-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1),(7,5,4,'unknown',0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(8,9,5,'unknown',0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(9,12,6,'unknown',0,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(10,2,7,'unknown',0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(11,2,8,'unknown',0,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
/*!40000 ALTER TABLE `metrics` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `people`
--
DROP TABLE IF EXISTS `people`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `people` (
`id` int(11) NOT NULL,
`name` varchar(255) DEFAULT NULL,
`email` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `people`
--
LOCK TABLES `people` WRITE;
/*!40000 ALTER TABLE `people` DISABLE KEYS */;
INSERT INTO `people` VALUES (1,'Eduardo Morais','companheiro.vermelho@gmail.com'),(2,'Zhongpeng Lin (林中鹏)','lin.zhp@gmail.com');
/*!40000 ALTER TABLE `people` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `repositories`
--
DROP TABLE IF EXISTS `repositories`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `repositories` (
`id` int(11) NOT NULL,
`uri` varchar(255) DEFAULT NULL,
`name` varchar(255) DEFAULT NULL,
`type` varchar(30) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `repositories`
--
LOCK TABLES `repositories` WRITE;
/*!40000 ALTER TABLE `repositories` DISABLE KEYS */;
INSERT INTO `repositories` VALUES (1,'/home/eduardo/input','input','git');
/*!40000 ALTER TABLE `repositories` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `scmlog`
--
DROP TABLE IF EXISTS `scmlog`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `scmlog` (
`id` int(11) NOT NULL,
`rev` mediumtext,
`committer_id` int(11) DEFAULT NULL,
`author_id` int(11) DEFAULT NULL,
`date` datetime DEFAULT NULL,
`author_date` datetime DEFAULT NULL,
`message` longtext,
`composed_rev` tinyint(1) DEFAULT NULL,
`repository_id` int(11) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `committer_id` (`committer_id`),
KEY `author_id` (`author_id`),
KEY `repository_id` (`repository_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `scmlog`
--
LOCK TABLES `scmlog` WRITE;
/*!40000 ALTER TABLE `scmlog` DISABLE KEYS */;
INSERT INTO `scmlog` VALUES (1,'bc57a9209f096a130dcc5ba7089a8663f758a703',1,1,'2012-08-14 14:30:13','2012-08-14 14:30:13',' Initial commit on test repository\n',0,1),(2,'87783129c3f00d2c81a3a8e585eb86a47e39891a',1,1,'2012-08-14 14:32:15','2012-08-14 14:32:15',' Renamed file\n',0,1),(3,'7debcf8a2f57f86663809c58b5c07a398be7674c',1,1,'2012-08-14 14:33:27','2012-08-14 14:33:27',' Added new file\n',0,1),(4,'c0d66f92a95e31c77be08dc9d0f11a16715d1885',1,1,'2012-08-14 14:35:02','2012-08-14 14:35:02',' Deleted and renamed file\n',0,1),(5,'c6ba8f7a1058db3e6b4bc6f1090e932b107605fb',1,1,'2012-08-14 14:45:51','2012-08-14 14:45:51',' Add one final file\n',0,1),(6,'589bb080f059834829a2a5955bebfd7c2baa110a',1,1,'2012-08-14 15:04:01','2012-08-14 15:04:01',' Create \"deeply\" nested file\n',0,1),(7,'ce8e0b86a1e9877f42fe9453ede418519115f367',2,2,'2014-02-11 22:07:49','2014-02-11 22:07:49',' rename aaa/otherthing\n',0,1),(8,'51a3b654f252210572297f47597b31527c475fb8',2,2,'2014-02-11 22:09:26','2014-02-11 22:09:26',' modify aaa/otherthing\n',0,1),(9,'456a68ee1407a77f3e804a30dff245bb6c6b872f',2,2,'2014-02-11 22:10:39','2014-02-11 22:10:39',' Merge branch \'lzp\'\n \n Conflicts:\n aaa/otherthing\n',0,1);
/*!40000 ALTER TABLE `scmlog` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `tag_revisions`
--
DROP TABLE IF EXISTS `tag_revisions`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `tag_revisions` (
`id` int(11) NOT NULL,
`tag_id` int(11) DEFAULT NULL,
`commit_id` int(11) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `tag_id` (`tag_id`),
KEY `commit_id` (`commit_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `tag_revisions`
--
LOCK TABLES `tag_revisions` WRITE;
/*!40000 ALTER TABLE `tag_revisions` DISABLE KEYS */;
/*!40000 ALTER TABLE `tag_revisions` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `tags`
--
DROP TABLE IF EXISTS `tags`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `tags` (
`id` int(11) NOT NULL,
`name` varchar(255) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `tags`
--
LOCK TABLES `tags` WRITE;
/*!40000 ALTER TABLE `tags` DISABLE KEYS */;
/*!40000 ALTER TABLE `tags` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Final view structure for view `action_files`
--
/*!50001 DROP TABLE IF EXISTS `action_files`*/;
/*!50001 DROP VIEW IF EXISTS `action_files`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = utf8 */;
/*!50001 SET character_set_results = utf8 */;
/*!50001 SET collation_connection = utf8_general_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `action_files` AS select `a`.`file_id` AS `file_id`,`a`.`id` AS `action_id`,`a`.`type` AS `action_type`,`a`.`commit_id` AS `commit_id` from `actions` `a` where (`a`.`type` <> 'R') union select `fc`.`to_id` AS `file_id`,`a`.`id` AS `action_id`,`a`.`type` AS `action_type`,`a`.`commit_id` AS `commit_id` from (`actions` `a` join `file_copies` `fc`) where ((`fc`.`action_id` = `a`.`id`) and (`a`.`type` = 'R')) */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `actions_file_names`
--
/*!50001 DROP TABLE IF EXISTS `actions_file_names`*/;
/*!50001 DROP VIEW IF EXISTS `actions_file_names`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = utf8 */;
/*!50001 SET character_set_results = utf8 */;
/*!50001 SET collation_connection = utf8_general_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `actions_file_names` AS select `a`.`id` AS `id`,`a`.`type` AS `type`,`a`.`file_id` AS `file_id`,`fc`.`new_file_name` AS `new_file_name`,`a`.`commit_id` AS `commit_id` from ((`actions` `a` join `scmlog` `s`) left join `file_copies` `fc` on((`a`.`id` = `fc`.`action_id`))) where (`s`.`id` = `a`.`commit_id`) */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!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 */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-- Dump completed on 2014-03-23 17:49:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment