Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
242 views
in Technique[技术] by (71.8m points)

mysql - autoincrement column in SQL database

I have two value in one table in database which I need to autoincrement. First value is ID it's a primary kay and it is setup as Identity Column and have (Is Identity) - Yes in properties. And how setup my second value (number) to autoincrement. When I setup his property (Is Identity) yes it automaticly change Identity Column for number.

Is possible to meke autoincrement for two value in one table in sql?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

It is not possible to have more than one identity column in a table (and I can't think of a valid reason for wanting to do so anyhow).


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...