Re: [news] Re: Status of MySQL AUTO_INCREMENT Support?

From: Andrus Adamchik (andru..bjectstyle.org)
Date: Thu Mar 31 2005 - 22:01:59 EST

  • Next message: Cris Daniluk: "RE: [news] Re: Status of MySQL AUTO_INCREMENT Support?"

    The question is whether it is being returned via
    java.sql.Statement.getGeneratedKeys() ... IIRC my earlier testing
    showed that it doesn't work...

    Andrus

    On Mar 31, 2005, at 9:50 PM, Cris Daniluk wrote:

    > Postgres has a mapping through the SERIAL datatype. However, I've
    > found its
    > use to be convoluting during prototyping, etc (it automatically
    > creates a
    > named sequence that isn't automatically dropped when the table is
    > dropped)
    >
    > However, it truly is automatic...
    >
    > Cris
    >>
    >> IMO auto-increment (aka generated keys) addition to JDBC
    >> standard is there to cause confusion :-) ... Driver support
    >> for it ranges from poor to non-existent. So on the database
    >> end you can have a number of mechanisms to get a PK generated
    >> on row insert (triggers being one of them), but propagating
    >> it to Java layer is another story... AFAIK only SQLServer and
    >> MySQL proprietary mechanisms have JDBC mapping (if you know
    >> of others, please post it here) ...
    >>
    >
    >



    This archive was generated by hypermail 2.0.0 : Thu Mar 31 2005 - 22:02:04 EST