一个 sql 逻辑运算的问题(pl/sql中的写法) select * from a where b与1>0 请问这样的语句在pl/sql中的应该怎么写,请高手赐教! 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 sorry:bitand()SELECT order_id, customer_id,DECODE(BITAND(order_status, 1), 1, 'Warehouse', 'PostOffice')Location,DECODE(BITAND(order_status, 2), 2, 'Ground', 'Air') Method,DECODE(BITAND(order_status, 4), 4, 'Insured', 'Certified') ReceiptFROM ordersWHERE order_status < 8;ORDER_ID CUSTOMER_ID LOCATION MET RECEIPT---------- ----------- ---------- --- ---------2458 101 Postoffice Air Certified2397 102 Warehouse Air Certified2454 103 Warehouse Air Certified2354 104 Postoffice Air Certified2358 105 Postoffice G Certified2381 106 Warehouse G Certified2440 107 Warehouse G Certified2357 108 Warehouse Air Insured2394 109 Warehouse Air Insured2435 144 Postoffice G Insured2455 145 Warehouse G Insured... UTL_RAW.BIT_AND ( r1 IN RAW, r2 IN RAW) RETURN RAW;select utl_raw.bit_and('0000','1111') from dual; sql 逻辑运算的问题select * from a where b与1>0 分成select * from a where b>0 and 1>0 不行么? 在线等 一个Sql语句 关于Oracle JDBC的问题 求一存储过程 exp模式 Oracle存储过程的问题 一个建表的问题(报 jsp中oracle连接池的配置 请问如何删除表的重复记录 三表链接查询的问题,报ORA-00933错误 一个关于DBMS_SQL的问题!谢谢。 简单的并发控制问题 急ORACE!
bitand()SELECT order_id, customer_id,
DECODE(BITAND(order_status, 1), 1, 'Warehouse', 'PostOffice')
Location,
DECODE(BITAND(order_status, 2), 2, 'Ground', 'Air') Method,
DECODE(BITAND(order_status, 4), 4, 'Insured', 'Certified') Receipt
FROM orders
WHERE order_status < 8;
ORDER_ID CUSTOMER_ID LOCATION MET RECEIPT
---------- ----------- ---------- --- ---------
2458 101 Postoffice Air Certified
2397 102 Warehouse Air Certified
2454 103 Warehouse Air Certified
2354 104 Postoffice Air Certified
2358 105 Postoffice G Certified
2381 106 Warehouse G Certified
2440 107 Warehouse G Certified
2357 108 Warehouse Air Insured
2394 109 Warehouse Air Insured
2435 144 Postoffice G Insured
2455 145 Warehouse G Insured
...
r1 IN RAW,
r2 IN RAW)
RETURN RAW;select utl_raw.bit_and('0000','1111') from dual;
select * from a where b与1>0 分成
select * from a where b>0 and 1>0
不行么?