472,117 Members | 2,451 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,117 software developers and data experts.

Problem in auto_increment


My database table containing a column name P_ID

Field Extra = P_ID,
Type = int(11),
Null = NO,
Key = PRI,
Default = NULL,
Extra = auto_increment

1. If I delete any row from my table (eg. P_ID = 2) I dont get that P_ID even I insert any new data. Is it for auto_increment?

2. If I want to remove auto_increment from that attribute, how it possible?

Advance thanks.
Feb 6 '08 #1
1 1224
802 Expert 512MB
1. Whenever you insert a new record, you get an incremented value. This is how auto_increment works.

2. Use the following query to remove auto_increment
Expand|Select|Wrap|Line Numbers
Feb 7 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

3 posts views Thread by Andrew | last post: by
5 posts views Thread by Paul Lamonby | last post: by
9 posts views Thread by Bart Van der Donck | last post: by
reply views Thread by Shailesh | last post: by
10 posts views Thread by Sjoerd | last post: by
1 post views Thread by webandwe | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.