在pl / sql中做bitor的好方法是什么?

时间:2015-05-05 05:00:59

标签: sql plsql bit bitwise-operators

在pl / sql中进行bitor操作的好方法是什么?

目前我们正在使用

#include <iostream>
#include <fstream>
#include <cstdlib>
using namespace std;


int main() {
  string ranger[50]; 
    ifstream rangerin("Ranger.txt");


    if ( !rangerin ) {
        cout << "Invalid File\n";
        return EXIT_FAILURE;
    }

    string message;

    while ( getline(rangerin, message) ) {

    }
}

提前致谢。

1 个答案:

答案 0 :(得分:1)

过去我对这种模拟感到满意

CREATE OR REPLACE FUNCTION bitor(x NUMBER, y NUMBER) RETURN NUMBER DETERMINISTIC
IS
BEGIN
    RETURN x - bitand(x, y) + y;
END;

和你的一样。 An explanation can be found here