An embedded database is one that runs internally instead of requiring
a separate database server.  This makes it convenient for standalone
applications.

For the database connection itself, though, you'd want something like:

JDBC URL: jdbc:h2:~/mydb
Username: sa
Password: <blank>

As for PostgreSQL support in H2, I don't know anything about that.  Sorry.

mrg


On Tue, Oct 20, 2009 at 8:00 PM, Eric Lazarus <[email protected]> wrote:
> Folks
>
> Thanks for you folks direction on using H2 as our database but we are a bit 
> stuck on how to do it. We are moving toward using Cayenne 3.0M6 and H2 for 
> the desktop version of an application that should be as idiot proof as 
> possible. We want for the end user to not have to understand that there is a 
> database there at all.
>
> Any suggestions about how we should configure things? For example, should we 
> configure H2 to run embedded if we don't want the end user to have to be 
> aware of it? How DO we configure it that way? What should we be reading to 
> figure out how to do that? I am not even sure we understand what it means to 
> run "embeded." Does that mean that that database is in the same VM? That we 
> don't go via JDBC at all?
>
> Also, we are trying to load a postgres dump into H2 and am failing because H2 
> does not support the COPY statement. I have tried enabling postgres 
> compatibility mode by appending ';MODE=PostgreSQL' to my database url. This 
> results in a error message stating 'File not found 'backup.sql'. I tried 
> putting my dump in a file by that name and got the same message.
>
> I also tried sticking 'SET MODE PostgreSQL ;' at the top of my SQL dump file. 
> This had no effect the script still abended with a syntax error on the COPY 
> command.
>
> Where the best place to ask H2 questions? Is there an IRC room? A list serve?
>
> thanks!
>
> Eric
>
> +1 (917) 589-6579
>
>
>

Reply via email to