Laurenz Albe wrote:I was trying to do exactly the same thing, and I found out that the> I have been asked to compose a query to return the metadata of a
> function or procedure (MySQL 5.0): argument names and types, IN or OUT,
> return value if appropriate.
> The ultimate goal is to provide these metadata to an application that
> accesses the database via .NET; the developer claims that there is no
> way to retrieve these data via the .NET driver and asked me for a
> Selecting INFORMATION_SCHEMA.ROUTINES.ROUTINE_DEFINITION returns only
> the function body.
> I had the idea to write a function that issues a SHOW CREATE FUNCTION
> and ps the result, but I am facing problems with this approach:
> - There is nothing like a 'SHOW ... INTO <variable>'
> - I considered declaring a cursor for the statement and retrieve the
> SHOW result this way.
> However, I found no way to declare a cursor for a dynamic statement.
> Can anybody think of a way to achieve my goal?
> Thank you,
> Laurenz Albe
only viable solution, as of today, is to p the output of
"SHOW CREATE FUNCTION ..." in the host language.
Quoting from the manual:
"INFORMATION_SCHEMA does not yet have a PARAMETERS table, so applications that need to acquire routine parameter
information at runtime must use workarounds such as parsing the output of SHOW CREATE statements."
_ _ _ _
(_|| | |(_|><