[Not so?] Stupid ODBC!

Lennon,

there appears to be no standard way of getting an identifier
for the last row inserted.
...
Does anyone have a general solution for this they've used
(or seen described/mentioned) elsewhere?

    Check out the "IdentifierType = SQL_BEST_ROWID" parameter of the
ODBC SQLSpecialColumns function. The MS reference is here:

m/odbcsqlspecialcolumns.asp. This function returns the column or
columns that uniquely identify each row in a table. These columns are
guaranteed to work in a WHERE clause. If there are no columns that
uniquely identify a row in the table, the function returns an empty
"rowset". This was introduced in ODBC 1.0, so it should be available
everywhere.

    I have never used it myself, but it sounds like exactly what you are
looking for.

    I'm guessing this will help :o)

    - Warren Brown