select * from memo like '%非典%'如果非典为一变量这样写对吗?
 select * from memo like '%:b%'

解决方案 »

  1.   

    select * from memo like '%'+非典+'%'不要使用LONG型,因为是ORACLE的淘汰类型,效率很低。
    建议你使用CLOB,BLOB类型。
      

  2.   

    LONG columns cannot appear in certain parts of SQL statements:GROUP BY clauses, ORDER BY clauses, or CONNECT BY clauses or with the DISTINCT operator in SELECT statements 
    The UNIQUE operator of a SELECT statement 
    The column list of a CREATE CLUSTER statement 
    The CLUSTER clause of a CREATE MATERIALIZED VIEW statement 
    SQL built-in functions, expressions, or conditions 
    SELECT lists of queries containing GROUP BY clauses 
    SELECT lists of subqueries or queries combined by the UNION, INTERSECT, or MINUS set operators 
    SELECT lists of CREATE TABLE ... AS SELECT statements 
    ALTER TABLE ... MOVE statements 
    SELECT lists in subqueries in INSERT statements