Inserting binary data types

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • embza
    New Member
    • Dec 2009
    • 4

    Inserting binary data types

    currently i have developed a C# application that makes ready structured variables holding binary values to be written into oracle database. The values to be inserted are different. some of them are as small as 1bit, 2bits, 3bit ....8bit, 2bytes,
    and the others are as large as 8,000 bytes and some may be 4Gigs larger.
    what data types should I use to store these values in my oracle10g database tables. Considering all the values are to be used by many users and are most of the time in the cache memory because they are overused every day.

    thank you all.
    Last edited by debasisdas; Dec 2 '09, 04:56 AM. Reason: snipped mail id.
  • debasisdas
    Recognized Expert Expert
    • Dec 2006
    • 8119

    #2
    You want to insert both 1 bit and 4 Gb data into a single field ?

    Comment

    • embza
      New Member
      • Dec 2009
      • 4

      #3
      No no,
      I want to insert 1bit, 2bit, 3bit .... 8bit , 4gbyte in different fields in the same table.
      so i want what datat types to use. I want for example the 1bit value to hold by a 1bit data type and the 2bit with 2bit datatype....mem ory utilization.

      Comment

      • debasisdas
        Recognized Expert Expert
        • Dec 2006
        • 8119

        #4
        find all the compatible details in the following links.

        link1
        link2
        link3
        link4
        link5

        Comment

        • embza
          New Member
          • Dec 2009
          • 4

          #5
          thanks debasisdas for the reply.
          I saw those links but there isn't any one of them
          that fits to my requirement.
          May be I have to create new data type(user defined one) that holds binary data.
          Or may be a mechanism to overload the char data type to hold binary data as one character.
          Eg.
          x = 00000010
          y char;
          y := x;
          so it is holding only one byte.
          My need was to create a data types like the below:
          It is a variable-length data type as the concept of arraylist.
          example:
          binary(1) is data type for one bit
          binary(2) is data type for two bits;
          binary(3) is data type for three bits
          .
          .
          binary(8) is data type for three bits.

          Do you think it is possible to do.
          How could database professionals possibly ignored this feature in their database technology.
          Thankyou
          Embza

          Comment

          • embza
            New Member
            • Dec 2009
            • 4

            #6
            Of all, the best of the better is using binary(n) or varbinary(n) of SQL server 2008.
            for 1 bit value u r going to allocate atleast 8 bits i.e binary(1).
            I don't have any other choice currently.
            Please tell if there is one.
            Thanks
            Embza

            Comment

            Working...