I do it using a stored procedure which has an output parameter which
passes back the IDENTITY column value. Here is an example:
CREATE PROCEDURE spInsert
output parameter */
AS
BEGIN
INSERT INTO table (dumb_value)
END
Then in ODBC you should bind a parameter to accept the identity value
and use the following SQL statement and pass it to SQLExecDirect():
"{ CALL spInsert(?, dumb_value) }"
That should work. Good luck.
George Khalifa
On Thu, 20 Mar 1997 12:04:53 -0800, "Enrique Travieso"
>Does anybody know of a way to obtain the the value of an IDENTITY column
>using ODBC/RDO after an INSERT query has been performed.
>I can issue another SELECT MAX(fieldname) query but that method does not
>hold up too well under multi-user access.
>Any help would be appreciated.
>Enrique Travieso