Reply
PhpMyAdmin and Procedures
Old 01-24-2008, 08:19 AM PhpMyAdmin and Procedures
carloncho's Avatar
Skilled Talker

Posts: 80
Name: Carlos
Is possible to use store procedures in phpMyAdmin? I dont find this possibility.
Thanks.
__________________
-----------------------
http://www.xumby.com
carloncho is offline
Reply With Quote
View Public Profile Visit carloncho's homepage!
 
When You Register, These Ads Go Away!
     
Old 01-25-2008, 11:23 AM Re: PhpMyAdmin and Procedures
reli4nt's Avatar
Extreme Talker

Posts: 153
Location: New York
The answer is yes and no. Phpmyadmin has no tools for creating stored procedures but you can enter in SQL using it and in that way create them.

(Note I don't believe versions prior to MySQL 5 supported stored procedures.)
__________________
The JPProject Multimedia
Designing the world we live in.
Defining the terms we live by.
reli4nt is offline
Reply With Quote
View Public Profile Visit reli4nt's homepage!
 
Old 01-27-2008, 12:48 AM Re: PhpMyAdmin and Procedures
carloncho's Avatar
Skilled Talker

Posts: 80
Name: Carlos
Iīve enter the script to create the procedure in the phpMyAdminīs SQL editor, but have an error. I have all permissions (is a local database). It didīt work
I continue work on it. thanks
__________________
-----------------------
http://www.xumby.com
carloncho is offline
Reply With Quote
View Public Profile Visit carloncho's homepage!
 
Old 01-27-2008, 12:50 AM Re: PhpMyAdmin and Procedures
carloncho's Avatar
Skilled Talker

Posts: 80
Name: Carlos
I forget: I use MySQL 5.0.51 and PHP 5.2.5.
__________________
-----------------------
http://www.xumby.com
carloncho is offline
Reply With Quote
View Public Profile Visit carloncho's homepage!
 
Old 01-27-2008, 01:13 AM Re: PhpMyAdmin and Procedures
reli4nt's Avatar
Extreme Talker

Posts: 153
Location: New York
What was the error?
__________________
The JPProject Multimedia
Designing the world we live in.
Defining the terms we live by.
reli4nt is offline
Reply With Quote
View Public Profile Visit reli4nt's homepage!
 
Old 01-27-2008, 05:23 PM Re: PhpMyAdmin and Procedures
carloncho's Avatar
Skilled Talker

Posts: 80
Name: Carlos
Quote:
CREATE PROCEDURE test.`get_count_users` ( IN param1 VARCHAR( 50 )

(X) -> ) BEGIN SET @SQL = CONCAT( "SELECT * FROM ", param1, ";" ) ;

Quote:
MySQL:
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 3
I put the same script in a SQL edit in Toad For MySQL and works good over the same database!! But phpMyAdmin donīt want to work with any procedure script
I test several scripts and the problem are the same. I think that phpMyAdmin not work with procedures. I search Web, but i didnīt found nothing about that
__________________
-----------------------
http://www.xumby.com
carloncho is offline
Reply With Quote
View Public Profile Visit carloncho's homepage!
 
Old 01-29-2008, 03:31 AM Re: PhpMyAdmin and Procedures
Average Talker

Posts: 21
check your MySQL version....
jigolo is offline
Reply With Quote
View Public Profile
 
Old 03-22-2008, 04:53 PM Re: PhpMyAdmin and Procedures
carloncho's Avatar
Skilled Talker

Posts: 80
Name: Carlos
Several years later, i post about this, sorry
Finally, i can use procedures with PHPMyAdmin, but i dont view as an DB Object. Simply i put the create sentence in SQL Editor and send. The procedure exists, i call from php, but the procedures i not listed in phpMyAdmin.
There is a chance to view procedures in phpMyAdmin?
__________________
-----------------------
http://www.xumby.com
carloncho is offline
Reply With Quote
View Public Profile Visit carloncho's homepage!
 
Old 03-22-2008, 05:04 PM Re: PhpMyAdmin and Procedures
reli4nt's Avatar
Extreme Talker

Posts: 153
Location: New York
I really don't think so. PhpMyadmin doesn't support stored procedures. Since it allows you to query the db you can create them but it doesn'thave any tools in place to support them.
__________________
The JPProject Multimedia
Designing the world we live in.
Defining the terms we live by.
reli4nt is offline
Reply With Quote
View Public Profile Visit reli4nt's homepage!
 
Old 03-22-2008, 11:52 PM Re: PhpMyAdmin and Procedures
joder's Avatar
Flipotron

Posts: 6,117
Name: James
Location: In the ocean.
In the PhpMyAdmin list of databases should be information_schema. In it is a table name ROUTINES. You query it by issuing a

Code:
select ROUTINE_NAME from ROUTINES;
This will output a list of Stored Procedure names. To see a procedure, run the query

Code:
show create procdure [procedure name from above select]
joder is offline
Reply With Quote
View Public Profile
 
Old 05-21-2008, 04:57 AM Re: PhpMyAdmin and Procedures
Junior Talker

Posts: 2
Hi

i am able to create procedures at phpmyadmin
can u plz let me know how to use those stored procedures in php
should i use call / execute statement in order to get those results of created stored procedure

thanks..
PavaniMadan is offline
Reply With Quote
View Public Profile
 
Old 05-26-2008, 06:11 PM Re: PhpMyAdmin and Procedures
Junior Talker

Posts: 2
Name: Ed Purkiss
If you are using mysqli or PDO stuff then it will work pretty much automatically. If you are using the older mysql_ functions, then you must add a flag to the connect directive:

mysql_connect($host, $user, $password, true, 65536);

the 65536 is a magic number flag to allow for multiple responses on the connection. It is not currently documented, but can be found in the php header file.

phpMyAdmin does a crummy job of working with stored procedures, functions and triggers - and executing them from the SQL window is also hit & miss.

I'm looking for anyone that would like to assist me with alpha and beta testing my new open source project, phpMyIDE which is a PHP/JS/Ajax application for managing database-embedded code for MySQL. It can be found here:
<edit>Link removed - Please don't throw original post off topic with your own requests and links</edit>

... many of the questions about working with stored procedures are answered with this app, making working with them a whole lot easier.

Thanks in advance to anyone willing to assist,
/p

Last edited by mgraphic : 05-27-2008 at 07:05 PM. Reason: removed link
Perkiset is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to PhpMyAdmin and Procedures
 

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML

 


Page generated in 0.15952 seconds with 13 queries