Re: ??Glob.Variable used in query for datablock??

From: <scott_j_felten_at_navtrans.navy.mil>
Date: 1998/03/11
Message-ID: <6e6gkh$mha$1_at_nnrp1.dejanews.com>#1/1


Neville,

   Thank you for your response... we were trying to place a global variable that contained the entire where clause...I probably was not clear. Upon suggestion of another we did...

"directly change the default-where-property of the block using set_block_property(blockname, default_where, ...) instead of using a variable in between."

This worked great. Isn't life fun!?!?!

Dorine

In article <01bd4ca6$6616e320$45f11286_at_itwol-pc3963.itwol.bhp.com.au>,   "Neville Sweet" <sweet.neville.nj_at_bhp.com.au.no_junk_today_thanks> wrote:
>
> Sorry for the brain-dead response.
>
> That should be:
> your_where_clause := your_global || ' < 500'
> where your_global holds the name of the column.
> In hindsight this is probably what you are already doing, so... what is the
> error message you are getting?
>
> Neville Sweet <sweet.neville.nj_at_bhp.com.au.no_junk_today_thanks> wrote in
> article <01bd4c9e$7cdf61c0$45f11286_at_itwol-pc3963.itwol.bhp.com.au>...
> > Dorine,
> >
> > > When referencing the global variable in the default where clause the
 actual
> > > value of the global variable appears, but it is enclosed with
 'single-quotes'.
> > > Under GLOBAL Variables in the debugger, the values were correct (ex.
 NumPieces
> > > was correct as was < and 500) Upon going into Debugger/SYSTEM
 Variables/LAST
> > > Query...the concatenation was as follows:
> > > 'NumPieces < 500' (we want ... NumPieces < 500 without the
 quotes!)
> > >
> > > This is what we want for the global variable to use in the default
 where
> > > clause. However, it would not work because of the single quotes.
> >
> > Are you sure this is the cause of the problem?
> > The information you provide is scant, but at a guess the problem is more
> > likely to be that the value of the global must be concatenated with the
> > rest of the string, ie.
> > your_where_clause := NumPieces || ' < 500';
> > Set_Block_Property(Your_Block,
> > DEFAULT_WHERE,
> > your_where_clause);
> > OR perhaps directly:
> > Set_Block_Property(Your_Block,
> > DEFAULT_WHERE,
> > NumPieces || ' < 500');
> >
>

-----== Posted via Deja News, The Leader in Internet Discussion ==----- http://www.dejanews.com/ Now offering spam-free web-based newsreading Received on Wed Mar 11 1998 - 00:00:00 CET

Original text of this message