Select Last Number In Access
I have recently been working on a ticketing system and i needed to know how to find they next number for the primary key. Took me a while to find out how to do it in access so i thought i would share it.
Here is this SQL that i used.
I know that with many of the better DBMS they can return the generated keys, But from what i found you can not do this with access.
If you have found any easier methods then please feel free to share them.

But as i said in the post MS access wont allow you to return generated keys.
Access is maybe better these days than it was many years ago. But there are far better databases to use than MS Access. Hell Coldfusion 8 comes with Derby and you can use other free DB's like mySQL or MS SQL Express to name a few.
It still amazes me why people still use MS Access, I see no good reason for it.
The only reason i used access was because it was a requirement in the specification.
I would have probably used oracle if it were up to me.
Otherwise, you'll run into issues using this code when multiple people start using it.
http://www.whatladybuys.com
http://www.whatladybuys.com
http://www.whatladybuys.com
http://www.whatladybuys.com
Nike air max 2010,air max 2009,air max shoes on sale.Buy nike air max shoes on http://www.nikeairmax-1.com low at $62,especially [url=http://www.nikeairmax-1.com/]air max 2010[/url],[url=http://www.nikeairmax-1.com/]air max 2009[/url],BOSE products include BOSE headphones,BOSE mobile in-ear, Bose earphones headphones [url=http://www.headphoneonsales.com/]cheap bose headphones[/url][url=http://www.headphoneonsales.com/]bose headphones[/url]