Results 1 to 5 of 5
  1. #1
    Join Date
    Sep 2004
    Posts
    3

    Unanswered: database user post extraction

    please can anyone help me i have a ipb forum some how i accidently delete my post i have a old backup from 3 week ago how can i extract the post from the backup
    NOTE: the only post that was deleted was post made by me none of the other member post was deleted
    i did not want to restore the entire post table beacause i would loose post in the past 3 weeks
    can anyone help me with a script or anything i can used to extract post of the post table where the poster id is 1
    here is a sample

    INSERT INTO `ibf_posts` VALUES (2, 0, NULL, 1, 'albertldee', 1, 1, '12.8.34.199'
    INSERT INTO `ibf_posts` VALUES (3, 0, NULL, 4, 'ޮѢ-Ѥ', 1, 1, '207.44.154.35
    INSERT INTO `ibf_posts` VALUES (4, 0, NULL, 6, 'demarcus', 1, 1, '69.142.131.149
    INSERT INTO `ibf_posts` VALUES (5, 0, NULL, 7, 'gottasteu', 1, 1, '65.12.169.41

    the post table has about 122000 line like above i just want to extract all the line that has albertldee like line number 1

  2. #2
    Join Date
    Jun 2003
    Location
    West Palm Beach, FL
    Posts
    2,713

    Cool

    Try something like:
    Code:
    INSERT INTO ibf_posts 
    SELECT * FROM ibf_posts_backup
     WHERE user_id = 'albertldee';
    NOTE: Change user_id to the correct column name.

    The person who says it can't be done should not interrupt the person doing it. -- Chinese proverb

  3. #3
    Join Date
    Sep 2004
    Posts
    3

    thanks but how do i set it up

    thanks but how do i set it up

  4. #4
    Join Date
    Sep 2004
    Posts
    3
    or can anyone tell me how can i setup a query to check a table and insert a line if it's not already exist

  5. #5
    Join Date
    Jun 2003
    Location
    West Palm Beach, FL
    Posts
    2,713

    Talking

    Post a description of both the 'ibf_posts' and the backup table.
    The person who says it can't be done should not interrupt the person doing it. -- Chinese proverb

Posting Permissions

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