Menu

Error: DB Error: no such table

Help
2004-02-09
2013-02-27
  • Monica Sterling

    Monica Sterling - 2004-02-09

    I have setup everything it works great for the most
    part. I can view and click print it displays. I can not, edit or delete. When I click a specific record it goes to a page and says;

    [Error: DB Error: no such table]

    I setup my regdb to reference two different databases. If I copy the table I'm trying to manipulate to the $maindb it won't error out, it just refreshes the page.  I checked to see if it was looking in the wrong database.

    What am I doing wrong?
    I have phpFriendlyAdmin 1.5(new install)
    Apache 2.x
    mysql 4.x
    php 4.3x

     
    • Martijn

      Martijn - 2004-07-07

      In your main_classes/User.php try to find this SQL statement:

              $sql = "SELECT * FROM " . $currenttable->dbtablename . " WHERE " . $currenttable->findid() . " = '" . $primarykey . "'";
             
      and change the single code line below that into this:

              $regdb = $currenttable->database->constring();
              $result = $regdb->query($sql);

      Your problems will be solved!

       
    • kwig

      kwig - 2004-09-30

      I have a similar problem and have done exactly what you have said here. My problems have not been solved. Admin works great, but when a user logs in and selects the table to edit, the search bar appears and below it: Error: DB Error: no such table. I have triple checked that the table on mysql mirrors the table/field set up in PFA. I have changed main_classes/user.php as described above. Still get the same results. Any other ideas? Please help. I have downloaded so many of these DB Management apps that just didn't work. At least with PFA I got it installed and running and had a bit of hope.  Thanks, kwig

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.