Here is the scoop. Last I checked Oleg was working on this for EJB 2.0, but I have trouble contacting him (our email servers don't like each other).
The way it will be implemented is with a lookup in JNDI that returns an object that implements some yet to be defined AutoNumber interface. I think the initial revision uses a sequence table. I don't think we will be able to support auto-generated columns, as this requires special sql in the insert statement or special handling of the prepared statement object. When we start seeing JDBC 3.0 drivers, which support auto-generated columns, we will be able to add generic support. To make a long story short, it should be in JBoss 3.0 final. -dain > -----Original Message----- > From: Andreas Schaefer [mailto:[EMAIL PROTECTED]] > Sent: Friday, January 11, 2002 4:50 AM > To: [EMAIL PROTECTED]; > [EMAIL PROTECTED] > Subject: Re: [JBoss-dev] Autogenerated primary keys etc > > > Hi > > This feature is difficult to implement because there is no > standard in the > DBs. > Some do like Oracle, PostgreSQL, some do it differentely like > M$ SQL-Server > and Sybase with the "Identity" table attribute and some do not provide > anything > like M$ Access. > > It becomes more difficult if you need autogeneraed PK > spawning over more > than > one DB. > > AFAIK there is a EJB around in JBoss generating PKs but I did > not use it. > > I don't think there is a general solution possible but I > would suggest that > you > create a SLSB delivering the generated PK and encapsulate the > implementation > in this EJB to separate DB specific details from your application. > > Andy > > ----- Original Message ----- > From: "Lennart Petersson" <[EMAIL PROTECTED]> > To: <[EMAIL PROTECTED]> > Sent: Friday, January 11, 2002 1:41 AM > Subject: Re: [JBoss-dev] Autogenerated primary keys etc > > > > Is this a feature supported by other J2EE servers? If so, > we should have > it also. > > If not, should we be first? I'm now in a situation that i > actually myself > would like to > > have that feature, but can't cover all the pros and cons > with it. Any > comments from > > others already been this way, i mean there has been plenty of > discussions... > > > > /Lennart > > > > Den 2002-01-11 08:27:02 skrev Alexey Yudichev > <[EMAIL PROTECTED]>: > > > > > Is somebody going to integrate autogenerated primary key > support to > jaws > > >like patch #473280? A very useful feature, I wonder why jboss still > doesn't > > >have one. > > > > > >Best wishes, > > > Alexei Yudichev mailto:[EMAIL PROTECTED] > > > > > > > > > > > > > _______________________________________________ > > Jboss-development mailing list > > [EMAIL PROTECTED] > > https://lists.sourceforge.net/lists/listinfo/jboss-development > > > > > _______________________________________________ > Jboss-development mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/jboss-development > _______________________________________________ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development