[DB-SIG] Another funny Oracle feature

Jim Fulton jim.fulton@Digicool.com
Fri, 26 Jun 1998 08:11:58 -0400


Another funny (ha ha, not really) feature I've found in Oracle is
that when binding parameters to SQL (not procedures, just SQL)
it is possible to have *output* parameters as well as input
parameters.  For example, someonw can use:

  select foo into :fooparm from spam where bar=:barparm

Now this select has two parameters. One is an input 
parameter and one is an output parameter. As a bonus, 
There doesn't seem to be any API call I can make to discover
that 'fooparm' is an output parameter.  But then, there isn't
an API call I can make to find out what parameters there
are either, so why am I complaining? :(

This situation is rather hard to handle with the current
DBI API.  This may be reasonable, since the SQL above is,
I assume, non-standard.  I'm curious if anyone else has 
come across a case like this with other databases?

BTW, the situation is not so bad for stored procedures, 
since there is an API for getting procedure metadata.

Jim

--
Jim Fulton           mailto:jim@digicool.com
Technical Director   (888) 344-4332              Python Powered!
Digital Creations    http://www.digicool.com     http://www.python.org

Under US Code Title 47, Sec.227(b)(1)(C), Sec.227(a)(2)(B) This email
address may not be added to any commercial mail list with out my
permission.  Violation of my privacy with advertising or SPAM will
result in a suit for a MINIMUM of $500 damages/incident, $1500 for
repeats.