Re: Constraint handling messed up?

From: Dirk Olmes (dirk.olme..mx.de)
Date: Thu Feb 06 2003 - 06:47:46 EST

  • Next message: Holger Hoffstätte: "Re: Postgres adaptor"

    Holger Hoffstätte wrote:
    > Dirk Olmes wrote:
    >
    >>I'm currently working on the postgres adaptor and it makes some progress
    >>(more in a separate mail). I've stumbled over the constraints also (but
    >
    > nifty! I'm actually compiling 7.3.2 as we speak.. :)
    > According to the mailing list the pg-jdbc driver seems to have many little
    > quirks, make sure you use the latest 7.3 release or even -dev.

    I do but even that doesn't help the BLOB support :-(
    Currently, in the pg-jdbc driver the only binary types that work are
    BINARY and VARBINARY. In the testmap.xml the PAINTING_INFO blob
    attribute is marked as LONGVARBINARY which makes the jdbc driver bail.
    bummer.

    AFAICS the only valid solution would be to make the pg-jdbc driver
    handle LONGVARBINARY and friends.

    >>On my last Oracle project declaring all constraints as deferrable
    >>initially deferred helped to avoid a lot of troubles and now I wonder if
    >
    > absolutely, but..
    >
    >>this wouldn't be a sensible default for oracle, too.
    >
    > ..at least for the unit tests having the constraints as strict as possible
    > is good for testing the statement sorting. INITIALLY DEFERRED might be a
    > last chance if there's a cyclic dependency that cannot be broken up.

    The whole problem arises when the unit tests try to tearDown and remove
    db rows that are still referenced from other tables. Then again, one
    could sit down and rearrange the SQL in the tear down methods
    appropriately. Alternatively one could try and order the setUp/tearDown
    SQL with ashwood ... any takers?

    The last full run of the tests still gave me 11 failures (mostly CHAR()
    agains VARCHAR() declarations) and 4 errors. I'll see how far I get
    later today ...

    -dirk



    This archive was generated by hypermail 2.0.0 : Thu Feb 06 2003 - 06:49:19 EST