Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想知道是否可以为 Oracle 编写虚拟更新命令以进行单元测试。
类似的东西
SELECT * FROM DUAL
假设你在某处有一张桌子,
UPDATE mytable SET myfield = 'foo' WHERE 1 = 0
选项1:创建一个虚拟表,在其中插入一行。瞧,你可以更新它。
选项2:创建一个虚拟视图,向它添加一个“而不是更新”触发器,它什么都不做。