[REBOL] Re: Newbie SELECT problem
From: volker:nitsch:gm:ail at: 7-Mar-2005 11:46
On Mon, 07 Mar 2005 08:15:05 +0100, SQLAB <[SQLAB--gmx--net]> wrote:
> Hi Ka=ED
>
> use this
> >> select block to-set-word "city"
> == "kelowna"
or
select [name: "kai" city: "kelowna" year: "2005"] [name:]
;put set-word in a block
or, the typical way:
obj: construct [name: "kai" city: "kelowna" year: "2005"]
obj/name
this is often used for configs,
config: construct load/all %config-file.r
> AR
>
> Kai Peters wrote:
>
> >Hi ~
> >
> >am trying to select from a decode-cgi block but cannot select set-words??
> >What am I doing wrong?
> >
> >As always, thanks for any help
> >
> >Kai
> >
> >
> >
> >
> >probe blk
> >
> >
> >[name: "kai" city: "kelowna" year: "2005"]
> >== [name: "kai" city: "kelowna" year: "2005"]
> >
> >
> >
> >>>select blk "kai"
> >>>
> >>>
> >== city:
> >
> >
> >
> >select blk city:
> >
> >
> >** Script Error: city needs a value
> >** Near: select blk city:
> >
> >
> >
> >>>select blk 'city:
> >>>
> >>>
> >** Syntax Error: Invalid word -- 'city:
> >** Near: (line 1) select blk 'city:
> >
> >
> >
> >>>select blk 'city
> >>>
> >>>
> >== none
> >
> >
> >
> >>>select blk city
> >>>
> >>>
> >** Script Error: city has no value
> >** Near: select blk city
> >
> >
> >
> >
> --
> To unsubscribe from the list, just send an email to rebol-request
> at rebol.com with unsubscribe as the subject.
>
--
-Volker
Any problem in computer science can be solved with another layer of
indirection. But that usually will create another problem.
David
Wheeler