wood burning stoves 2.0*
The moose likes JDBC and the fly likes Retrieve Stored Procedure Code Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Retrieve Stored Procedure Code" Watch "Retrieve Stored Procedure Code" New topic
Author

Retrieve Stored Procedure Code

Gregg Bolinger
GenRocket Founder
Ranch Hand

Joined: Jul 11, 2001
Posts: 15299
    
    6

Is there a way to retrieve the actual sql code from a stored procedure in MySQL. Also, is there a way to get the names of all the stored procedures in a database without knowing them?


GenRocket - Experts at Building Test Data
Dave Vick
Ranch Hand

Joined: May 10, 2001
Posts: 3244
Gregg
Check out the getProcedures method of the DatabaseMetaData class. It lloks like ti might return the actual code too.
hope that is what you were looking for.


Dave
Gregg Bolinger
GenRocket Founder
Ranch Hand

Joined: Jul 11, 2001
Posts: 15299
    
    6

Dave my savior. Thank you very much.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Retrieve Stored Procedure Code