Subject | Re: [IBO] DSQL and EXECUTE PROCEDURE |
---|---|
Author | Helen Borrie |
Post date | 2006-03-06T09:28:20Z |
At 08:01 PM 6/03/2006, you wrote:
Params are both input and output, and determined by ParamType
(ptInput, ptOutput). You'll need to test what you're getting in
TIBODataset but it's possibly surfacing the TDataset behaviour.
Why would you use a grid for a single row of output? Grids are for
SELECT statements.
Yes, I know you said you were using TIBODataset because you had some
spiffy grid you wanted to use...but you don't get rows as output to
an executable procedure, you get a single set of values (one for each
output arg).
The only way I know of that you're going to get "griddable" output is
to put a SUSPEND statement in the SP and select from it. But that's
doesn't work with your data interface, which is designed to work with
multi-row output.
You could have a look at how Lorenzo does it in IBOConsole. He has a
separate interface for executable DSQL and delivers the result into
fields. Or look at the DSQL tab of Jason's IB_SQL.
I'm wondering how you cope with interactive DDL in DBW....do you
display an empty grid afterwards, or what?
Helen
> > EXECUTE PROCEDURE FOO (:p1);In native IBO, Params are inputs and Fields are outputs. In TDataset,
> >
> > When it's prepared, the server will send the description of the
> > xsqlvar back in the xsqlda structure; then the dataset will know to
> > anticipate the return value.
>
>So, this won't return a resultset, but will create, what? Objects
>in the .Params property? .Fields? How would this be visible
>in a grid, if at all?
Params are both input and output, and determined by ParamType
(ptInput, ptOutput). You'll need to test what you're getting in
TIBODataset but it's possibly surfacing the TDataset behaviour.
Why would you use a grid for a single row of output? Grids are for
SELECT statements.
Yes, I know you said you were using TIBODataset because you had some
spiffy grid you wanted to use...but you don't get rows as output to
an executable procedure, you get a single set of values (one for each
output arg).
The only way I know of that you're going to get "griddable" output is
to put a SUSPEND statement in the SP and select from it. But that's
doesn't work with your data interface, which is designed to work with
multi-row output.
You could have a look at how Lorenzo does it in IBOConsole. He has a
separate interface for executable DSQL and delivers the result into
fields. Or look at the DSQL tab of Jason's IB_SQL.
I'm wondering how you cope with interactive DDL in DBW....do you
display an empty grid afterwards, or what?
Helen