ORA-00932: inconsistent datatypes: expected - got CLOB

SQL> SELECT DISTINCT D.SQL_ID, D.SQL_FULLTEXT, D.SQL_TEXT
  2    FROM V$SQL D
  3   WHERE D.SQL_ID = 'fsuzhxtaw402x';

 

ORA-00932: inconsistent datatypes: expected - got CLOB

 

-- 由于SQL_FULLTEXT是CLOB类型,可能是oracle不支持对CLOB类型的distinct   去掉distinct后查询正常

 

SQL> SELECT D.SQL_ID, D.SQL_FULLTEXT, D.SQL_TEXT
  2    FROM V$SQL D
  3   WHERE D.SQL_ID = 'fsuzhxtaw402x';

 

SQL_ID              SQL_FULLTEXT                                          SQL_TEXT                                       
-------------------  --------------------------------------------------      ------------------------------------------------
fsuzhxtaw402x  select seq_pmain.nextval from dual     select seq_pmain.nextval from dual
fsuzhxtaw402x  select seq_pmain.nextval from dual     select seq_pmain.nextval from dual

 

引用:http://blog.csdn.net/lwei_998/article/details/6387279

你可能感兴趣的:(expect)