How to retrieve last autoincremented value in MS-Access like @@Identity in Sql Server
I wan开发者_如何学Pythont to retrieve identity column value in ms access from an autoincremented column. Basically i m running a transaction in which i have to write two insert queries. 2nd query will be containing autoincremented value that was generated from query 1. how can i do that ?
However, Microsoft Access 2000 or later does support the @@IDENTITY property to retrieve the value of an Autonumber field after an INSERT
Source: Retrieving Identity or Autonumber Values
EDIT: As noted by @David-W-Fenton, you'll also need to use Jet 4.0 OLE DB Provider
(this is also described into that previous document)
精彩评论