Re: [PHP] Query Analyzer For MySQL with PHP?
At 02:56 PM 4/23/2001, Brandon Orther wrote: teh guys a phpwizzard.net wrote phpmyadmin...its a wonderful db admin tool...and it has a feature like what your describing.check it out...http://www.phpwizzards.net ~kurth Hello, I recently took an ANSI SQL class to better familiarize my self with SQL in general. In the class we used MSSQL SERVER 7 and to do queries we used the Query Analyzer. Does anyone know of a PHP script that works like the Query Analyzer so I can test Queries in a Browser? Like A Text Area where I can put the query and a simple form that sends it to MySQL. Thanks, Brandon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Query Analyzer For MySQL with PHP?
If you want to input SQL querries through a text box, you can just build an easy one in PHP. Note: it's extremely unsecure to use for anything more than personal use. Just create an HTML form with a textarea and a submit button. Set the action to the php page and on the PHP page do something like this (we'll say the textarea name is query): if ($query) { $result = mysql_query($query); } if (!$result) { echo mysql_error(); } else { for ($res_num = 1; $row = mysql_fetch_assoc($result); $res_num++) { echo Result number $rew_num: ; print_r($row); } } Sure it ain't pretty and you should change the print_r() call to a more controllable function, but it works just fine. You'll of course have to connect to the database and all before doing this, and change the database functions to fit your chosen database, but you get the idea. phpMyAdmin has a more fully featured type deal though, and the above works only for SELECT statements in MySQL. -- Plutarck Should be working on something... ...but forgot what it was. Brandon Orther [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hello, I recently took an ANSI SQL class to better familiarize my self with SQL in general. In the class we used MSSQL SERVER 7 and to do queries we used the Query Analyzer. Does anyone know of a PHP script that works like the Query Analyzer so I can test Queries in a Browser? Like A Text Area where I can put the query and a simple form that sends it to MySQL. Thanks, Brandon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] Query Analyzer For MySQL with PHP?
Brandon: Search www.freshmeat.net for phpmyadmin. It's a great little tool to help you administer MySQL, including executing arbitrary SQL statements. There are several others there as well. Freshmeat has plenty of tools to get you going. hth Chris -Original Message- From: Brandon Orther [mailto:[EMAIL PROTECTED]] Sent: Monday, April 23, 2001 1:56 PM To: PHP User Group Subject: [PHP] Query Analyzer For MySQL with PHP? Hello, I recently took an ANSI SQL class to better familiarize my self with SQL in general. In the class we used MSSQL SERVER 7 and to do queries we used the Query Analyzer. Does anyone know of a PHP script that works like the Query Analyzer so I can test Queries in a Browser? Like A Text Area where I can put the query and a simple form that sends it to MySQL. Thanks, Brandon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Query Analyzer For MySQL with PHP?
Use the mysql monitor, from shell: mysql -u username -p dbname That'll log you in, now run some queries : mysqlSELECT * FROM tablename; At this point everything is selected and displayed from table tablename. In otherwords, we can run and view SQL queries from this console, much like MySQL does it for PHP. Here are a couple tutorials that should help : MySQL Monitor Tutorial : http://www.mysql.com/doc/T/u/Tutorial.html MySQL Tutorial (demonstrates monitor) : http://www.devshed.com/Server_Side/MySQL/Intro/ Also, phpMyAdmin has a place to enter and view such queries via a form. phpMyAdmin : http://www.phpwizard.net/projects/phpMyAdmin/ Regards, Philip On Mon, 23 Apr 2001, Brandon Orther wrote: Hello, I recently took an ANSI SQL class to better familiarize my self with SQL in general. In the class we used MSSQL SERVER 7 and to do queries we used the Query Analyzer. Does anyone know of a PHP script that works like the Query Analyzer so I can test Queries in a Browser? Like A Text Area where I can put the query and a simple form that sends it to MySQL. Thanks, Brandon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] Query Analyzer For MySQL with PHP?
Create a mysql odbc acces and download the winsql.exe program that works with odbc connections ,its a great sql client !! Sebastián Renzi ConsultorÃa Desarrollo de Sistemas. CODES S.A -Mensaje original- De: Philip Olson [SMTP:[EMAIL PROTECTED]] Enviado el: lunes 23 de abril de 2001 16:47 Para: Brandon Orther CC: PHP User Group Asunto: Re: [PHP] Query Analyzer For MySQL with PHP? Use the mysql monitor, from shell: mysql -u username -p dbname That'll log you in, now run some queries : mysqlSELECT * FROM tablename; At this point everything is selected and displayed from table tablename. In otherwords, we can run and view SQL queries from this console, much like MySQL does it for PHP. Here are a couple tutorials that should help : MySQL Monitor Tutorial : http://www.mysql.com/doc/T/u/Tutorial.html MySQL Tutorial (demonstrates monitor) : http://www.devshed.com/Server_Side/MySQL/Intro/ Also, phpMyAdmin has a place to enter and view such queries via a form. phpMyAdmin : http://www.phpwizard.net/projects/phpMyAdmin/ Regards, Philip On Mon, 23 Apr 2001, Brandon Orther wrote: Hello, I recently took an ANSI SQL class to better familiarize my self with SQL in general. In the class we used MSSQL SERVER 7 and to do queries we used the Query Analyzer. Does anyone know of a PHP script that works like the Query Analyzer so I can test Queries in a Browser? Like A Text Area where I can put the query and a simple form that sends it to MySQL. Thanks, Brandon -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]