Results 1 to 5 of 5

Thread: Deleting Primary Key value

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Nov 2002
    Location
    Malaysia
    Posts
    124

    Deleting Primary Key value

    Hi, I have a Access table and ID is the primary key field for instance, but i can't add record anymore after i deleted one of the record. It showed me an exception error message with 'number has already presence'. But this problem solved when i exit my program and operate it again. Can anyone tell me what is the problem?

  2. #2
    Addicted Member CoMMiE's Avatar
    Join Date
    Jul 2000
    Location
    Malaysia, Kuala Lumpur
    Posts
    179
    hi
    try inserting a none duplicate id on the primary key column

  3. #3

    Thread Starter
    Lively Member
    Join Date
    Nov 2002
    Location
    Malaysia
    Posts
    124

    I tried before

    It still displays the same error message no matter what value i typed in the Primary Key Field

  4. #4
    Fanatic Member Mr.No's Avatar
    Join Date
    Sep 2002
    Location
    Mauritius
    Posts
    651
    chinhow

    Try repairing the Access database. Is your primary key column an Autonumber field. If yes you can't explicitly set a value.
    Using VB.NET 2003/.NET 1.1/C# 2.0
    http://del.icio.us/rajoo
    Blow your mind, smoke gunpowder
    Ashes to ashes, dust to dust
    If God won't have you, the devil will. - Author unknown
    Don't follow me, I'm lost too ...

  5. #5

    Thread Starter
    Lively Member
    Join Date
    Nov 2002
    Location
    Malaysia
    Posts
    124

    It's not a autonumber field

    my primary key is not a autonumber field

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width