mySQL Stored Procedure

Talk about working with different database types

Moderators: ne_moj, zewa, vadimako, ne_moj, zewa, vadimako

kasumovic
Expert
Expert
Posts: 87
Joined: Sep 7th, '10, 22:38

mySQL Stored Procedure

Postby kasumovic » Sep 12th, '10, 16:41

Hi,

What workarround would be for using stored procedures ?

regards
kasumovic

administrator
Site Admin
Site Admin
Posts: 5992
Joined: Jan 7th, '09, 23:18
Contact:

Re: mySQL Stored Procedure

Postby administrator » Sep 13th, '10, 10:25

You may use them in your SQL statements

nsavellano
Newbie
Newbie
Posts: 1
Joined: Sep 28th, '10, 19:38

Re: mySQL Stored Procedure

Postby nsavellano » Sep 28th, '10, 20:40

Hi, is the ability to call the stored proc only in the Advance or Pro editions? The free version seems to have errors when replacing the select sql statement with the stored proc, "call sp_name();". Thanks!

administrator
Site Admin
Site Admin
Posts: 5992
Joined: Jan 7th, '09, 23:18
Contact:

Re: mySQL Stored Procedure

Postby administrator » Sep 29th, '10, 10:03

You cannot fully replace select sql with stored procedure, but you may use it in your SELECts

kasumovic
Expert
Expert
Posts: 87
Joined: Sep 7th, '10, 22:38

Re: mySQL Stored Procedure

Postby kasumovic » Nov 6th, '10, 19:25

You can use this in SELECT statement in Databases what this supports, like :
- Firebird
- Interbase

Simply call : "SELECT * FROM your_stored_procedure (your_params)"

at moment (ver.6.1.1) is not possible to use stored procedure in this way with mysql database, cause calling stored procedures are little bit different as in Firebird/Interbase case:

Call : "CALL your_procedure(you_input_params,@outparam_1,@outparam_2) ; select @outparam_1,@outparam_2"

I would suggest following strategy :

1.) Create Stored Procedure what populate Temporary Table
2.) Use your Temporary Table, cause dgrid can handle table without problems
example : "CALL your_procedure(input_param1,input_param2) ; select field1,field2,field3... from your_temporary_table"

hope this can help you


Return to “Databases: different types implementation”