[daisy] Postgresql support

Andreas Deininger adeininger at googlemail.com
Fri Aug 3 01:59:14 CDT 2007


2007/5/2, David Goodenough <david.goodenough at linkchoose.co.uk>:
> I realise that the core development of Daisy is done using MySql,
> but I wonder if there are any others like me who would like to get
> Postgresql support working.

Yes, it's me :-)

>  It is of course quite possible that
> work has already started somewhere.

Yes, I did :-).

> For the record I tried installing 2.0.1 using Postgresql, and found
> that the only apart problem was that when creating table wf_pools the
> unique constraint for the name_ field was given a name of name_ and
> postgresql complained that an object of that name (the field) already
> existed.  However when I created the table manually everthing else
> seemed to work.

This has been fixed with SVN 4288.

> However when I tried to do the daisy-wiki-init I got a failure:-
>
>                                 Schema creation
>                                 ===============
>
> Field type MultiMediaObjectAutoplay : created
> Exception in thread "main" java.lang.Exception: Error importing field type
> BookPath
>         at
> org.outerj.daisy.tools.importexport.import_.schema.SchemaLoader.load(SchemaLoader.java:65)
>         at
> org.outerj.daisy.tools.importexport.import_.schema.SchemaLoader.run(SchemaLoader.java:55)
>         at
> org.outerj.daisy.tools.importexport.import_.schema.SchemaLoader.load(SchemaLoader.java:43)
>         at
> org.outerj.daisy.install.SchemaUploader.load(SchemaUploader.java:94)
>         at
> org.outerj.daisy.install.DaisyWikiInit.installSchema(DaisyWikiInit.java:147)
>         at
> org.outerj.daisy.install.DaisyWikiInit.install(DaisyWikiInit.java:105)
>         at org.outerj.daisy.install.DaisyWikiInit.main(DaisyWikiInit.java:52)
> Caused by: org.outerj.daisy.repository.RepositoryException: Received exception
> from repository server.
>         at
> org.outerj.daisy.repository.clientimpl.infrastructure.DaisyHttpClient.handleNotOkResponse(DaisyHttpClient.java:180)
>         at
> org.outerj.daisy.repository.clientimpl.infrastructure.DaisyHttpClient.executeMethod(DaisyHttpClient.java:111)
>         at
> org.outerj.daisy.repository.clientimpl.schema.RemoteSchemaStrategy.store(RemoteSchemaStrategy.java:254)
>         at
> org.outerj.daisy.repository.commonimpl.schema.FieldTypeImpl.save(FieldTypeImpl.java:271)
>         at
> org.outerj.daisy.repository.commonimpl.schema.FieldTypeWrapper.save(FieldTypeWrapper.java:160)
>         at
> org.outerj.daisy.tools.importexport.import_.schema.SchemaLoader.handleFieldType(SchemaLoader.java:157)
>         at
> org.outerj.daisy.tools.importexport.import_.schema.SchemaLoader.load(SchemaLoader.java:63)
>         ... 6 more
> Caused by:
> org.outerj.daisy.repository.clientimpl.infrastructure.DaisyPropagatedException:
> [org.outerj.daisy.repository.RepositoryException] Error storing field type.
> Caused by:
> org.outerj.daisy.repository.clientimpl.infrastructure.DaisyPropagatedException:
> [org.postgresql.util.PSQLException] ERROR: value too long for type character
> varying(255)
>
> which is odd.

It is. I don't see this problem while using PostgreSQL 8.2 on the
lastest SVN. What version of PostgreSQL you are using?

> Anyone got any ideas, or is anyone else working on getting Postgresql support
> working.  If there is anyone perhaps we should work together to get around
> the problem(s).

There are still two patches pending, however, from my point of view,
the core functionality of Daisy should be available with PostgreSQL
now. You may check out the latest SVN and try it by yourself. Feel
free to report any problems you may encounter.

Regards
Andreas


More information about the daisy mailing list