From: Daevid Vincent Date: October 10 2006 7:38am Subject: RE: What's the PHP equivallent of "mysql mydb < somefile.sql" List-Archive: http://lists.mysql.com/mysql/202484 Message-Id: <009701c6ec3f$18494e70$450a0a0a@locutus> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Could you be more specific? What is "SOURCE"? Where do I use that? I = tried to search, but I find a lot of hits related to source code.=20 > -----Original Message----- > From: Ligaya A. Turmelle [mailto:lturmelle@stripped]=20 > Sent: Monday, October 09, 2006 6:57 PM > To: Daevid Vincent; mysql@stripped > Subject: RE: What's the PHP equivallent of "mysql mydb < somefile.sql" >=20 > I don't know if it will work - but have you tried using=20 > SOURCE in the mysql query?=20 >=20 > -----Original Message----- > From: Daevid Vincent [mailto:daevid@stripped]=20 > Sent: Tuesday, October 10, 2006 11:01 AM > To: mysql@stripped > Subject: What's the PHP equivallent of "mysql mydb < somefile.sql" >=20 > Currently I run an 'updater' script to run through a=20 > directory of .sql files using something like this in PHP: >=20 > $COMMAND =3D "mysql ".$OPTION['db_prefix'].$db." <=20 > ".$mydir.$filename; > system($COMMAND, $ret); >=20 > What would be the equivallent way to to this in a PHP=20 > mysql_query(""); way? >=20 > I see "LOAD", but that only works for data it seems. > http://dev.mysql.com/doc/refman/5.0/en/load-data.html >=20 > These scripts I use have ALTER statements and CREATE and all=20 > other types of SQL in them and almost no data actually. >=20 > mySQL 5.0.15 >=20 >=20 > =D0=C65=CF=D0=20 >=20 >=20 > -- > MySQL General Mailing List > For list archives: http://lists.mysql.com/mysql > To unsubscribe: http://lists.mysql.com/mysql?unsub=3Dlig@stripped >=20 >=20 >=20