views:

577

answers:

2

I've got a SQL Anywhere 9 database, and I would like to reset the autoincrement value on one of my columns to a specific number.

I guess I need the SQL-Anywhere equivalent of:

ALTER TABLE foo AUTO_INCREMENT =100

+1  A: 

A google search turned up this. I have never used SQL Anywhere, so I'm afraid I can't help anymore.

Jean Azzopardi
Thanks, just pulled up http://www.ianywhere.com/developer/product_manuals/sqlanywhere/0902/en/html/dbrfen9/00000662.htm and found the specific syntax for system functions
Brohan
Glad to be of some use..
Jean Azzopardi
+3  A: 

Just so the answer is actually here, not just linked to:

Use the sa_reset_identity system procedure:

sa_reset_identity (
  [ table_name
  [, owner
  [, new_identity_value ] ] ]
)
Graeme Perrow