but of  course Krista, that would only work with BMP wouldn't it?

there's an article on orionsupport regarding counter.jar and how you can use
it to GENERATE unique id's
if you are required to use an IDENTITY field on the db, you're stuck with
BMP

JP

-----Original Message-----
From: Krista Richmond [mailto:[EMAIL PROTECTED]]
Sent: Martes, 30 de Enero de 2001 12:03
To: Orion-Interest
Subject: RE: When using autonumber for the primarykey...


If it's actually an autonumber field (at least with SQL Server), just insert
the rest of the fields (not including the autonumbered field), e.g.
(presuming your table includes First_Name,Last_Name, and an
autonumber...say, a Customer_ID field): 

"INSERT INTO tblMyData(First_Name,Last_Name) VALUES('Sam','Adams')"

The table will automatically generate the autonumber for the ID field, hence
the name ;-).  Additionally, if you *try* to insert a value into the
autonumber field, SQL Server will generate an error.  I'm not sure whether
there may be different behaviors in different DBs...anyone?

HTH

-----Original Message-----
From: Øystein Walle [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, January 30, 2001 3:37 AM
To: Orion-Interest
Subject: When using autonumber for the primarykey...



I'm just wondering what to do when inserting into a table where the
primarykey has incremental int type? 
Is this possible?

Please help.

Walle



Reply via email to