How do expressions work with OTHER datatype?

2010-10-12 Thread Joonas Pulakka
When using the OTHER data type (serialized Java objects), do expressions (i.e. NAME='Hi') compare simply the serialized byte array (for exact equivalence), or is the (deserialized) object's equals method used? If equals is not currently used, could it be added as feature request? Thanks, Joonas -

Re: How do expressions work with OTHER datatype?

2010-10-13 Thread Rami
While I am sympathetic to your cause I am not very happy about the OTHER type. Why? Well, what happens when an other language accesses a column like that. That issue is already concrete when using the ODBC connectivity from let's say php. Also there is an other type in jdbc spec called JAVA_OBJ

Re: How do expressions work with OTHER datatype?

2010-10-13 Thread Joonas Pulakka
I do realize that: - OTHER type is language specific. - Comparing them (with equals or compareTo) would require deserializing each single row, which would be orders of magnitude slower than comparing primitive types. - Deserializing at the server side is as security hazard. - Therefore, in general

Re: How do expressions work with OTHER datatype?

2010-10-14 Thread Rami
The original question ultimately boils down to whether the author wants to keep H2 a "true & pure DBMS", or allow adding some goodies that are handy in some situations. I don't think the issue is best captured by setting against each other some obscure ideology of truth and purity with the

Re: How do expressions work with OTHER datatype?

2010-10-14 Thread Sergi Vladykin
Hi, > Also UUID is a bit odd. It is said to be 128 bits (16 bytes = 2*bigint) > long. > So it could be more generically expressed as BINARY(16) UUID actually is not just a 16 bytes but it's a type strictly defined by RFC. The most important it has well defined string representation to be easily i

Re: How do expressions work with OTHER datatype?

2010-10-14 Thread Rami
UUID actually is not just a 16 bytes but it's a type strictly defined by RFC. The most important it has well defined string representation to be easily interchangable between different kinds of software. So higher level of generality you are talking about will lack this feature. Ok, good to

Re: How do expressions work with OTHER datatype?

2010-10-15 Thread Sergi Vladykin
Hi, > Maybe something like this could be added to the documentation: > (Copied from wikipedia) I think that UUID is not a h2 specific thing so there is no reason to steal work from google and wikipedia. > I assume that if someone does not provide all 32 digits and 4 hyphens an > exception is thr

Re: How do expressions work with OTHER datatype?

2010-10-15 Thread Rami Ojares
On 15.10.2010 14:04, Sergi Vladykin wrote: I think that UUID is not a h2 specific thing so there is no reason to steal work from google and wikipedia. Steal work from google and wikipedia? Did you mean to say share and spread the knowledge freely offered by google and wikipedia to the whole wo

Re: How do expressions work with OTHER datatype?

2010-10-15 Thread Joonas Pulakka
On Oct 14, 10:45 pm, Sergi Vladykin wrote: > But I agree that good user defined type system would be nice. So do I. What's good engineering practice to someone may seem like architecture astronautism to others. User defined types (as Rami described) would let both "sides" to be happy. For exampl

Re: How do expressions work with OTHER datatype?

2010-10-15 Thread Dario Fassi
Hi, El 15/10/10 08:04, Sergi Vladykin escribió >> Maybe something like this could be added to the documentation: >> (Copied from wikipedia) > I think that UUID is not a h2 specific thing so there is no reason to > steal work from google and wikipedia. A simple link to the relevant documentation

Re: How do expressions work with OTHER datatype?

2010-10-17 Thread Sergi Vladykin
Hi, > For me personally this description left many questions open and I would > have been better served with some > more background and details about the type. > > Do you feel that the current documentation is as complete as it can get? Of course there is nothing ideal in this world.. But I agree

Re: How do expressions work with OTHER datatype?

2010-10-21 Thread Thomas Mueller
Hi, > How do expressions work with OTHER datatype? It compares the byte array. See also http://h2database.com/html/datatypes.html#other_type > could it be added as feature request? Sure. It's not one of my priorities, but I can add a feature request. I would need to know how wou

Re: How do expressions work with OTHER datatype?

2010-10-24 Thread Joonas Pulakka
On Oct 22, 9:18 am, Thomas Mueller wrote: > Hi, > > > How do expressions work with OTHER datatype? > > It compares the byte array. See > alsohttp://h2database.com/html/datatypes.html#other_type > > > could it be added as feature request? > > Sure. It's

Re: How do expressions work with OTHER datatype?

2010-10-24 Thread Dario Fassi
Hi, AFICS, such a feature would be targeted to most common uses of OTHER, STRUCT, JAVA_OBJECT, BINARY and BLOBS sql data types that are used as generic containers: 1) Serialized java objects 2) Files content on database ( images, documents content, etc) 3) UDT (db user defined types) - this is a

Re: How do expressions work with OTHER datatype?

2010-10-28 Thread Thomas Mueller
Hi, I think comparison of large binary data (BLOBs) should be discussed in another topic. The new "lob in database" feature does now use a checksum (hash code), but not a cryptographic one. If the checksum matches, the content is compared (so that equal blocks are shared). I considered using a cry

Re: How do expressions work with OTHER datatype?

2010-10-28 Thread Dario Fassi
Hi, El 28/10/10 15:19, Thomas Mueller escribió: > I think comparison of large binary data (BLOBs) should be discussed in > another topic. No problem, but I still talking about binary. > The new "lob in database" feature does now use a > checksum (hash code), but not a cryptographic one. Great,

Re: How do expressions work with OTHER datatype?

2010-10-29 Thread Joonas Pulakka
On Oct 28, 9:19 pm, Thomas Mueller wrote: > Hi, > > I think comparison of large binary data (BLOBs) should be discussed in > another topic. The new "lob in database" feature does now use a > checksum (hash code), but not a cryptographic one. If the checksum > matches, the content is compared (so t

Re: How do expressions work with OTHER datatype?

2010-10-29 Thread Dario Fassi
Hi, El 29/10/10 10:04, Joonas Pulakka escribió: > On Oct 28, 9:19 pm, Thomas Mueller > > The new "lob in database" feature does now use a > checksum (hash code), I considered using a cryptographic checksum, ... In > most cases it would slow down adding BLOBs too > much I believe. > if a Java o

Re: How do expressions work with OTHER datatype?

2010-10-30 Thread Thomas Mueller
subject of this topic is "How do expressions work with OTHER datatype?". I fail to see how your discussion about checksum, digest, and so on relates to OTHER data type in any way. Regards, Thomas -- You received this message because you are subscribed to the Google Groups "H2 Da