On Sat, Jul 30, 2011 at 12:10 PM, John Hardin <jh...@im...> wrote:
>
> > or how to modify the Informix plugin for Squirrel so that I can see the
> > procs list in the db browser.
>
> That I don't know. I use Informix a lot, but I haven't looked at this
> particular part of Squirrel so I can't offer any advice. Sorry.
>
>
I am however very familiar with that part of SQuirreL. And John is correct,
the "?" is a placeholder in something called a prepared statement that
indicates to the database that this is a bind variable and that a subsequent
call to execute the query will provide the values. This saves the database
from having to re-parse the SQL and re-build the execution plan each time it
is executed. The SQuirreL editor doesn't provide a way to execute prepared
statements directly. The Informix plugin however uses them. This
particular query doesn't return the list of procedures; it returns the
source code for one of them. It requires that you have access to the the
tables informix.sysprocedures and informix.sysprocbody. If you do not, then
the query for procedure source will fail and the source will not be shown.
Furthermore, as stated in the documentation, you need access to all of the
following Informix tables for all of the functionality that the plugin
provides to work properly:
- informix.sysfragments
- informix.sysindices
- sysmaster:informix.sysptnhdr
- informix.sysprocbody
- informix.sysprocedures
- informix.systables
- informix.systriggers
- informix.systrigbody
- informix.sysviews
That said, the query that returns a list of stored procedures is actually
implemented as a standard JDBC API call that the JDBC driver implements.
SQuirreL defers to the JDBC driver for this. It's possible that the version
of the Informix JDBC driver that you are using has a bug. I seem to recall
running into this - or something like it - in the past. I worked with Doug
Lawry (An Informix User Group leader in the UK) who independently verified
the stored procedure source feature worked properly. Can you check the
version of your JDBC driver to make sure it is the latest?
Rob
|