Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Bitwise operators and binary data

Bitwise operators and binary data

From: Greg Stark <greg-spare-1_at_mit.edu>
Date: Thu, 10 Feb 2000 09:41:16 GMT
Message-ID: <87snz1l7ih.fsf@HSE-Montreal-ppp33976.qc.sympatico.ca>

I would like to store sets of boolean values in my database. I would like to be able to search on them using boolean operators to combine arbitrary sets of flags. The most obvious form to store the data is as bitfields either as large numbers or as binary data.

I'm happy to use binary data as it would let me control precisely how many bits to allocate and my client side code can deal nicely with hex data. But sometimes I want to do big queries on the DB side to find how many records would match certain masks.

Is it possible to apply bitwise operators to binary data in Oracle? If not, how large an integer type can I declare and can I rely on the integer type to behave properly without slipping into scientific notation or anything silly like that?

--
greg Received on Thu Feb 10 2000 - 03:41:16 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US