DB
yang_kunlun
这个作者很懒,什么都没留下…
展开
-
Find parent nodes in time trees by SQL
1.Find all ancestor node from child.SELECT parent.name from time_trees as parent,time_trees as node where node.lft between parent.lft and parent.rgt and node.original_id='0036994d34de9862-03-00000...2009-05-14 11:10:37 · 82 阅读 · 0 评论 -
SQL inner join usage
1.select time_trees.id,name,lft,rgt,parent_id,project_id,SUM(wEnd)-sum(wBegin) as wEnd from time_trees inner join work_items on work_items.project_id = time_trees.original_id and work_items.dayinf...2009-05-14 11:11:37 · 71 阅读 · 0 评论 -
Mysql and git study resource
http://dev.mysql.com/tech-resources/articles/hierarchical-data.htmlhttp://blog.xkoder.com/2008/08/13/git-tutorial-starting-with-git-using-just-10-commands/http://www.linuxsir.org/main/doc/git/...2009-05-14 11:30:43 · 73 阅读 · 0 评论 -
SQL example
SELECT items.Name AS Name , Work_Items AS '#no Workitems', sec_to_time(Project_Time) AS 'Client/Project Total Time', sec_to_time(Ticket_project_Time) AS 'Client/Project Time...2009-05-14 12:02:29 · 306 阅读 · 0 评论 -
SQL example 2
SELECT root_proj.r_proj AS root_project_name , great_proj.g_proj AS great_project_name , parent_proj.p_proj AS parent_project_name , proj.project AS project_name, task.task_...2009-05-14 12:57:40 · 98 阅读 · 0 评论 -
MongoMapper 试用小记
1. 安装mongo db2. sudo mkdir -p /data/db #默认的数据库读取目录3. 启动 mongo 服务器 sudo bin/mongod4. gem listmongo (0.19.1)mongo_ext (0.19.1)mongo_mapper (0.7.0)5. # config/environment.rbconfig.gem ...2010-03-03 14:19:11 · 174 阅读 · 0 评论