select segment_type,segment_name,(select count(*) from segment_name) RowsNum
from dba_segments where tablespace_name = 'USERS' and segment_type = 'TABLE'
就是那个计数项怎么报错呢???不会不支持自查询吧?
...全文
1235打赏收藏
这个SQL语句怎么不对了??
我以sysdba身份登录系统 select segment_type,segment_name,(select count(*) from segment_name) RowsNum from dba_segments where tablespace_name = 'USERS' and segment_type = 'TABLE' 就是那个计数项怎么报错呢???不会不支持自查询吧?
这样修改:
select segment_type,segment_name,coun(*) RowsNum
from dba_segments where tablespace_name = 'USERS' and segment_type = 'TABLE'
group by segment_type,segment_name