刚刚INSERT的记录找不到了,代码如下insert into tt(p,f,h,k) values('222','1','中国人','6');
select count(*)from tt;这两名话执行完后,返回TT的总记录数增加一条,然后再执行select count(*)from tt;发现刚才增加的记录没了,这是怎么实现的呢?太神奇了
select count(*)from tt;这两名话执行完后,返回TT的总记录数增加一条,然后再执行select count(*)from tt;发现刚才增加的记录没了,这是怎么实现的呢?太神奇了
你需要commit一下。
在别的会话才能看到你的执行结果
insert完后要用commit提交后,其他session才能看到的
WHERE TABLE_NAME = 'YOUR_TABLE';
Connected as look
SQL> drop table t1;
Table dropped
SQL> create table t1(c1 char(1));
Table created
SQL> insert into t1(c1) values('a');
1 row inserted
SQL> select * from t1;
C1
--
a
SQL> select * from t1;
C1
--
aConnected to Oracle9i Enterprise Edition Release 9.2.0.1.0
Connected as look
SQL> select * from t1;
C1
--
SQL>