select id,name,substr(max(sys_connect_by_path(tool,'/')),2) from
(select a.id,a.name,b.id bid,b.tool ,row_number() over(partition by a.id order by b.tool) t from a,b where a.id=b.id(+) group by a.id,a.name,b.id,b.tool)
connect by prior t=t-1 start with t=1 group by id,name;
时间太急,有事要出去,没测试,应该没有太大问题,你测试一下,回来再说
(select a.id,a.name,b.id bid,b.tool ,row_number() over(partition by a.id order by b.tool) t from a,b where a.id=b.id(+) group by a.id,a.name,b.id,b.tool)
connect by prior t=t-1 start with t=1 group by id,name;
时间太急,有事要出去,没测试,应该没有太大问题,你测试一下,回来再说
解决方案 »
- xp系统现在装了oracle和PL/SQL,如何装一个oracle服务器版本
- 请问这样的数据库怎么设计?
- 如何将多行数据合并成一行多列
- oci ,以及dmalloc問題請教 , 我由chinaunix,轉戰itpub,都沒人願意出手,只好請csdn高手幫忙
- oracel如何回滚操作的事务
- 能否在客户端同时装oracle8i和oracle9i,根据不同需要进行转换!
- 如何获知数据库的当前活动状态?
- oracleDBA宝典(PDF)哪里有下载??
- 求教:存储空间问题
- 特别菜的问题,请帮忙
- 用Oracle10g带的instant client连接Oracle,无需安装oracle客户端
- 请问10g是不是包含9i的全部功能呢?
我按照这个运行
也许是库的数据量太大了
运行不出来中间这部分
(select a.id,a.name,b.id bid,b.tool ,row_number() over(partition by a.id order by b.tool) t from a,b where a.id=b.id(+) group by a.id,a.name,b.id,b.tool)
可以运行出来但是一起,运行了2个小时了,还没出用toad运行的
connect by prior t=t-1 start with t=1 group by id,name;
有问题呢?
感觉有点像
谢谢Visual_Studio_Net(打鼠英雄) 啊
看来要把数结构给构建好就可以 connect by
因为是在家,没库
等去单位在试试