| 
 Posted by himilecyclist on 07/26/06 15:18 
I am trying to use the SQL "SELECT INTO" to create a copy of a MySQL 
database. 
 
My PHP code looks like this: 
 
<?php 
 
//Connect to server and database 
 
include ("Connections/ovrs.inc"); 
 
if (isset($_POST['cmdBackup'])) 
{ 
	$sql = "SELECT * INTO edenbackup FROM edenmaster"; 
 
 
	$result = mysql_query($sql) or die 
(ErrorCall(mysql_error(),"frmBackup.php","1")); 
 
	echo "The Backup is Complete"; 
} 
 
?> 
 
I get an SQL error when running this.  If I change the SQL Statement to 
be "SELECT * FROM edenmaster" it works fine, so I know the connection 
is OK. 
 
What is the correct syntax for "SELECT * INTO" for MySQL? 
 
Thanks!
 
  
Navigation:
[Reply to this message] 
 |