Re: Problem with Database Generated IDs and Firebird

From: John Armstrong (siberia..mail.com)
Date: Mon Aug 17 2009 - 13:53:21 EDT

  • Next message: akira: "Multi Domain deploy problem"

    If its a real issue I'd love to.

    Since no one else has reported it I'll check it against M6 and then
    give it a go.

    Tx Mike,
    John-

    On Mon, Aug 17, 2009 at 10:00 AM, Mike Kienenberger<mkienen..mail.com> wrote:
    > Maybe you could create a patch for it?  I don't know how many others
    > are actively using firebird.
    >
    > I would expect that fixing the Firebird adaptor, especially when you
    > have the mysql adaptor as a reference, would be an entry-level
    > contribution.
    >
    > On Mon, Aug 17, 2009 at 1:50 AM, John Armstrong<siberia..iberian.org> wrote:
    >> I am attempting to use database generated IDs with Cayenne 3.0M5 and
    >> Firebird. Even though isGenerated="true" on the proper column it still
    >> queries the AUTO_PK_SUPPORT table.
    >>
    >> Even more problematic is that the SQL generated seems invalid:
    >>
    >> === updated 1 row.
    >> INSERT INTO CLIENT (ACTIVECLIENT, CLIENTID, CLIENTSETTINGS,
    >> CLIENTVERSION, COMPANY, ID, LASTUPDATE) VALUES (?, ?, ?, ?, ?, ?, ?)
    >> [bind: 1->ACTIVECLIENT:NULL, 2->CLIENTID:'CLTSun Aug 16 22:39:58 PDT
    >> 200...', 3->CLIENTSETTINGS:200, 4->CLIENTVERSION:200, 5->COMPANY:260,
    >> 6->LASTUPDATE:200, 7->LASTUPDATE:NULL]
    >> === updated 1 row.
    >>
    >> Pay particular attention to argument 6 and 7. In the insert field list
    >> it names 6 as 'ID' (which should not be there) but in the actual
    >> insert it pushes 7 (LASTUPDATE) into 6 as the integer it got from
    >> AUTO_PK_SUPPORT (200 in this case) and then sets LASTUPDATE to null.
    >>
    >> I have not tried M6, I've had bad luck with the M6 modeler, so before
    >> I wrestle with M6 and see if this is problem still exists has anyone
    >> else seen it?
    >>
    >> Note that this works fine with mysql.. It seems FBDriver specific.
    >>
    >> John-
    >>
    >



    This archive was generated by hypermail 2.0.0 : Mon Aug 17 2009 - 13:53:56 EDT