Please consider updating http://www.h2database.com/html/advanced.html#mvcc
which says* The MVCC mode is enabled by default in version 1.4.x, with the
default MVStore storage engine. *
Best,
Joonas
maanantai 25. huhtikuuta 2016 9.40.39 UTC+3 Noel Grandin kirjoitti:
>
> Hi
>
> Aaaarh, you are us
There is an open issue about shutdown defrag corrupting db,
https://github.com/h2database/h2database/issues/187 . I've had similar
issue with non-split 1.4.190 DB. In my case the issue was, when opening DB
that was shut down with shutdown defrag,
Caused by: java.lang.ClassCastException: org.h2.
code, with connection pool):
>
> repeat maxRetries
> c = getConnection
> c.execute "..."
> c.execute "..."
> c.commit
> finally
> c.close
>
> Regards,
> Thomas
>
>
> On Mon, Sep 28, 2015 at 10:08 AM, Joonas Pulakka >
happens to be handled the way it is handled currently, or is there a
specific reason why is has to be handled that way?
Best Regards,
Joonas
perjantai 25. syyskuuta 2015 13.37.15 UTC+3 Joonas Pulakka kirjoitti:
>
> From http://h2database.com/html/features.html#auto_mixed_mode and
> ht
>From http://h2database.com/html/features.html#auto_mixed_mode and
http://h2database.com/html/features.html#auto_reconnect :
- (Mixed mode) When the first connection is closed, the server stops. If
other (remote) connections are still open, one of them will then start a
server (auto-re
> blocks. This mechanism sometimes removes entries that are still used. I
> have a fix now and will commit it to trunk.
>
> Regards,
> Thomas
>
>
> On Monday, March 23, 2015, Joonas Pulakka
> wrote:
>
>> Hello,
>>
>> According to documentati
Hello,
According to documentation, *closing the last connection closes the
database* (http://www.h2database.com/html/cheatSheet.html) and *when
closing the database, the database is automatically compacted for up to 200
milliseconds *(http://www.h2database.com/html/features.html#compacting). I
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
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 not one of my priorities, but I can add a fe
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
lso comparable (implement comparable
> interface)?
>
> Are you sure you can't decompose the data that your object houses into
> proper types in database?
> Or are you just wishing to dump a whole lot of information into database
> quickly
> without too much hassle?
>
>
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
-
Hello,
Ok, so it was just a bug. No problem then :-)
Best Regards,
Joonas
--
You received this message because you are subscribed to the Google Groups "H2
Database" group.
To post to this group, send email to h2-datab...@googlegroups.com.
To unsubscribe from this group, send email to
h2-datab
Version 1.2.143 contained the following change: "If the user name and
password are not set or empty, then the password is not hashed. To
disable this behavior, set the system property h2.emptyPassword to
false."
As a consequence, setting the above mentioned system property seems to
be required in
s. I also don't know of a way to get the primary keys for a
> simple update statement. Do other databases support such a feature?
>
> Regards,
> Thomas
>
>
>
> On Thursday, August 5, 2010, Joonas Pulakka wrote:
> > Ok, given that the "de facto" default star
ah(id identity(7,2), val varchar(10));
>
> insert into blah(val) values ('X')
> insert into blah(val) values ('Y')
>
> select * from blah
>
> ... and the results will be:
>
> id val
> 7 X
> 9 Y
>
> So as long as you didn
I need to get the primary key for the affected row after performing a
MERGE statement, regardless of whether the row got inserted or
updated. Is there a standard way to do that? Using the generated key
from the statement was my first idea, but it doesn't work quite that
way:
http://www.h2database.
Patches are the recommended way to provide urgently needed features:
http://www.h2database.com/html/build.html#providing_patches
Best Regards,
Joonas
On 21 huhti, 00:35, feci wrote:
> Hi,
>
> can you point me to page, where is written how to contribute, if I
> want to create new functions?
> I'
You can use ThreadLocal to store one Connection per thread. Something
like:
ThreadLocal connectionHolder = new
ThreadLocal();
public Connection getConnection() {
Connection c = connectionHolder.get();
if (c == null) {
c = (get a new connection for this thread from DriverManager
o
The JDBC spec doesn't require Connection to be thread-safe. But H2's
Connection (http://www.h2database.com/javadoc/org/h2/jdbc/
JdbcConnection.html) is thread-safe. So yes, it's a kind of weird: as
long as you use H2, you'll be fine, but since you're doing it "wrong",
you'll lose interchangeability
JDBC ResultSet offers getObject, getInt, getString etc. methods, and
PreparedStatement has analogous setters. Since (according to
http://www.h2database.com/html/datatypes.html) H2 is mapping
primitives to their boxed counterparts anyway, do the type specific
getters/setters have any (dis)advantages
On 25 maalis, 13:18, Sergi Vladykin
wrote:
> Yes, new connections will be rejected with error code 90135, so you
> can write a loop to reconnect (may be after a little waiting) when you
> get such an
> exception.http://h2database.com/javadoc/org/h2/constant/ErrorCode.html?#c90135
Great that ther
On 25 maalis, 12:58, Sergi Vladykin
wrote:
> Hi,
>
> See http://h2database.com/html/grammar.html#set_exclusive
Ah, excellent! Does just what I wanted. Just one question: what does
it mean that "new connections are rejected"? If someone happens to
call DriverManager.getConnection() on an unlucky m
I want to acquire a lock on the whole database for a moment in order
to perform a couple of operations in atomic fashion. That is,
synchronized(???) {
performACoupleOfOperationsAtomically();
}
Which lock does H2 use internally to guard its state? I should
obviously use the same lo
On 22 maalis, 22:07, Thomas Mueller
wrote:
> Hi,
>
> > I think the key must be the Connection object
>
> It will create two distinct trigger objects. The init method of the
> trigger will also contain the table name and so on. The unique
> identifier of a database is usually the database URL by th
Hi,
I wonder how I should approach this abmiguousity problem. Let's say
that I have a trigger created into a database "A" like this:
CREATE TRIGGER IF NOT EXISTS UsersModifiedTrigger AFTER INSERT,
UPDATE, DELETE ON users FOR EACH ROW CALL "MyTrigger"
Now, MyTrigger's fire() method gets calle
According to http://h2database.com/html/features.html#multiple_connections
H2 is multithreading-safe. But does this also apply to the Connection
object returned by DriverManager.getConnection("jdbc:h2:etc"), or
should I create separate Connections for each thread in a
multithreaded application? The
Thanks,
So my question is basically, what are the settings that give the best
durability against power interrupts, given that sacrificing speed is
OK in my application. I would assume that setting WRITE_DELAY=0, using
CHECKPOINT SYNC all around, and using clustering (where practical)
would be the
On Mar 17, 5:00 pm, Tim wrote:
> While trying to open my H2 database recently, I've run into an
> exception that hasn't been happening in the past. The only thing I
> can think of that has changed is that I moved the database from a
> networked PC to my development PC, but I know that the connect
I need to make an embedded Java database as fault tolerant (power
interrupt, JVM crash) as possible. Losing data from a few seconds
before the crash is acceptable, but the rest of the database should
not be corrupted in any way, and restarting the application should be
easy.
http://www.h2database.
30 matches
Mail list logo