Hi,

I'm trying to use H2 in unit tests.  After I start it up I execute all
of the database update scripts in a directory to make it the same as
our PostgreSQL database.   I'm finding some syntax doesn't work in H2
even though I set  ;mode=PostgreSQL in my JDBC connect string:

CREATE SEQUENCE history_id_seq INCREMENT 1 START 1;

CREATE TABLE history
(
    id integer NOT NULL PRIMARY KEY DEFAULT nextval('history_id_seq')
)

H2 complains about  DEFAULT[*] and says it expect DEFAULT 0  ?   How
can I tell it to use the next value from a sequence as the default
value, as I do in postgres?

Another query that fails is my CREATE ROLE queries:

CREATE ROLE myapp LOGIN ENCRYPTED PASSWORD
'md5.............................'
 NOSUPERUSER NOINHERIT NOCREATEDB NOCREATEROLE;

It complains about LOGIN.  I looked at the H2 documentation and CREATE
ROLE doesn't show any of those keywords.


Thanks,
Ryan

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/h2-database?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to