FreePgs.com Forum

FreePgs Related => Support Requests => Topic started by: doctoreast on February 17, 2007, 09:59:11 PM

Title: MYSQL IMPORT PROBLEM
Post by: doctoreast on February 17, 2007, 09:59:11 PM
Hi,

  I've been fighting a dbase file for months,
trying to get the file to import.  I contacted
admin, and they tell me to break the dbase
into several sections, so that I can locate the
problem table.

  Well, admin/Ben is correct, in that I was able
to single out the problem table, called template
which is the table which contains all of my CMS
php/html includes. 

  The table is 1.3mb in size, and my question is, would
this size cause a time-out error on freepgs settings? 
I've done several things, otherwise, trying to correct
a possible error,  but I need to know if it's timing-out,
no error, before I keep wasting my time with this monster.

east
Title: Re: MYSQL IMPORT PROBLEM
Post by: brainiac744 on February 18, 2007, 04:59:48 AM
It's possible that it's a time-out error...

I assume you're trying to import it using PMA? If so, can you describe what happens when you try to import the file.

If that doesn't work, can you take the part of the query that actually creates the table and run it successfully?
Title: Re: MYSQL IMPORT PROBLEM
Post by: lotsofish on February 24, 2007, 05:21:20 PM
Yes, time-out error definitely. Upload the SQL file and create a simple PHP script to import it instead.

(Untested)

<?
mysql_connect("mysql5.freepgs.com","username","password");
mysql_select_db("database");

$fp=fopen("filename.sql","r");
$sql="";
while(!feof($fp)){
  $sql.=fgets($fp);
}

mysql_query($sql);
?>


Good luck.
Title: Re: MYSQL IMPORT PROBLEM
Post by: bonehead on February 26, 2007, 06:14:59 AM
Or you can import and resume when it ends.