Results 1 to 3 of 3
  1. #1
    Join Date
    Mar 2012
    Posts
    2

    Unanswered: SQL Deletes all records

    Hi,
    There seems to be a problem with the SQL/PHP. When I select one row to be deleted, all of the records within the whole table gets deleted.
    I have no idea whats going on and tried a number of different things which hasnt working.
    How can I fix this issue?

    - Thanks

  2. #2
    Join Date
    Jan 2007
    Location
    UK
    Posts
    11,434
    Provided Answers: 10
    I assume you are using phpMyAdimin?
    I am also assuming you have no key field?

    We need more details.

    Have you tried writing your own DELETE statement?
    e.g.
    Code:
    DELETE
    FROM   your_table
    WHERE  one_field = 'a value'
    George
    Home | Blog

  3. #3
    Join Date
    Mar 2012
    Posts
    2
    FIXED:
    There was no auto incrementing primary key. Added that and it seems to be working now .

    Thanks for the quick replies

Posting Permissions

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