change the starting vaule for an autonumber field access 2007

  • Follow


how do I change the starting value for an autonumber field in access 2007
0
Reply Utf 1/18/2008 5:41:00 PM

(...)
> how do I change the starting value for an autonumber field in access 2007

DoCmd.RunSQL "alter table Table1 alter column ID counter(X,1)"

X - starting value

K.P.


0
Reply Krzysztof 1/18/2008 6:36:43 PM



"Richard" wrote:

> how do I change the starting value for an autonumber field in access 2007
0
Reply Utf 1/18/2008 7:17:01 PM

How exactly do I do that? Where do I enter that line? Sorry for my ignorance!

"Krzysztof Pozorek [MVP]" wrote:

> (...)
> > how do I change the starting value for an autonumber field in access 2007
> 
> DoCmd.RunSQL "alter table Table1 alter column ID counter(X,1)"
> 
> X - starting value
> 
> K.P.
> 
> 
> 
0
Reply Utf 2/14/2008 10:38:00 PM

You may use it in a query:
alter table Table1 alter column ID counter(1,1)

or in VBA code (module, immediate window):
DoCmd.RunSQL "alter table Table1 alter column ID counter(1,1)"

K.P. MVP, Poland
www.access.vis.pl


(...)
> How exactly do I do that? Where do I enter that line? Sorry for my 
> ignorance!
>
> "Krzysztof Pozorek [MVP]" wrote:
>
>> (...)
>> > how do I change the starting value for an autonumber field in access 
>> > 2007
>>
>> DoCmd.RunSQL "alter table Table1 alter column ID counter(X,1)"
>>
>> X - starting value
>>
>> K.P.
>>
>>
>> 


0
Reply Krzysztof 2/18/2008 9:39:52 AM

4 Replies
884 Views

(page loaded in 1.769 seconds)

Similiar Articles:













8/1/2012 9:37:33 AM


Reply: