Re: Passing Parameters to Query in Query Builder

From: Chris <c.beltz_at_chartermichigan.net>
Date: Mon, 6 Oct 2003 21:03:29 -0400
Message-ID: <vo441udiden60b_at_corp.supernews.com>


[Quoted] "Hans Forbrich" <forbrich_at_yahoo.net> wrote in message news:3F81FC9D.8B7D88BD_at_yahoo.net...
> Chris wrote:
>
> > All,
> > I'm new to Oracle, and I have been getting familiar with Query Builder.
The
> > interface is pretty intuitive. The only thing I cannot figure out is
how to
> > create prompts for parameters to pass to the WHERE criteria. I have
> > discovered how to create the parameters (name, prompt and default
value),
> > but I cannot figure out how to add them to the WHERE criteria text boxes
(in
> > the left pane of the Query window) without getting a syntax error.
> >
> > Valid syntax used in SQL*Plus:
> >
> > SELECT field FROM table WHERE field LIKE &parameter;
> >
> > does not seem to be valid in Query Builder, because I get a syntax
error,
> > with the ampersand highlighted.
>
> &parameter is used for 'substituting user parameters'. The actual
statement in
> pure SQL generally requires a string literal - but you can use wildcard
> characters (eg: % is multi-char wildcard). So you would use
>
> SELECT field FROM table WHERE field LIKE 'ABC%';
>
> to get anything starting with ABC (note case sensitivity).
>
> There is a lot more described in the docco

I understand this. I think there is a disconnect ... I am talking specifically about using the Query Builder GUI tool (not a statement at the [Quoted] SQL> prompt in SQL*Plus) which allows one to create parameters by giving them a name, prompt and default value.
Using your SQL above, I want to be able to open the query in Query Builder, [Quoted] have it prompt me for a value, enter the value "ABC%" and have it construct [Quoted] the WHERE criteria just as you have written.

>
> >
> > I cannot read the manual, because the help files have not been
installed,
> > and I could not find any documentation at http://otn.oracle.com. Can
anyone
> > help? Thank you greatly.
> >
>
> You didn't notice the 'Documentation' icon at the top of the page? In any
case,
> you can jump right into the OTN Docs area using http://docs.oracle.com, or
use
> http://tahiti.oracle.com for a slightly different access. (Both require a
valid
> OTN userid).

[Quoted] Of course, but I did not find any documentation for Query Builder. Did you [Quoted] try searching for documentation for Query Builder? If so, did you find any? [Quoted] If so, could you please post it?

Chris

> --
> /Hans
> [mailto:`echo $from" | sed "s/yahoo/telusplanet/g"`]
>
>
Received on Tue Oct 07 2003 - 03:03:29 CEST

Original text of this message