Function BIN_TO_NUM |
The PL/SQL example below converts a number (45 in this example) into binary value (101101). Using PL/SQL Reverse Loop, the binary value is used as input to the function to get the numeric value. The binary values have to be passed as comma seperated value to the function BIN_TO_NUM(1,0,1,1,0,1). The reverse computation to get the numeric value is done by calling the function BIN_TO_NUM() using dynamic sql and passing the binary values as a numeric array. |
72835