有关位运算符(& |)的问题
zwyyl 2004-03-23 01:56:03 我在 sybase 中看到这样的句子:
if (@in_day = 1)
update Careplancomment
set stat1 = ((stat1 & 0x2) | @flag)
where careuid = @in_careUserID
and planid = @in_planID
and seq = @in_seq
-----------------------------
flag :tinyint
in_day : smallint
stat1 : tinyint 型的 。
主要是想知道(& |)的用法, sybase 和 pl/sql是不是都一样的?
pl/sql中类似的写法是怎样的,望指教!