CREATETABLE test( id number(20, 0) NOTNULLPRIMARY KEY, FieldAA varchar2(64), FieldAB varchar2(64), flag varchar(2) );
1 2 3 4 5
insertinto test values(1, 'a1','b1','D'); insertinto test values(2, 'a2','b2',''); insertinto test values(3, 'a3','b3',''); insertinto test values(4, 'a4','b4','B'); insertinto test values(5, 'a5','b5','');
2. <> 和 is not null
1
SELECT t.*FROM test t;
1
SELECT t.*FROM test t where t.flag <>'D'or t.flag isnull;