There's a slight problem with the syntax, namely if you read

select=tag:blog&select=tag:coment

quickly. the "&" sticks in the mind and it gets parsed as

select=tag:blog&tag:coment

that is as an intersection rather than a union. What I'm trying to say
is I'm used to applying the boolean before the selection rather than
after it and so a cursory glance is misread. I don't think I'm
atypical in that respect.

Martin


2009/4/29 [email protected] <[email protected]>:
>
> On Apr 29, 12:46 pm, Jeremy Ruston <[email protected]> wrote:
>> I'd also given thought to the difference between selection and
>> filtering. My simplistic way of fitting them together was to invent
>> the idea of a implicit selector at the start of a filter list. Thus, a
>> construction like "[tag[blog]sort[modified]limit[10]]" would be
>> treated as "[select[*]tag[blog]sort[modified]limit[10]]".
>
> Yeah, that's perniciously hard to reliably parse for both a person (at
> least this) and a computer, and it couples into the same engine three
> very different pieces of functionality. That coupling is what you
> might call anathema to the TiddlyWebWayâ„¢.
>
> As things currently stand filters in TiddlyWeb are though of as a
> single query parameter on a URL (?filter=<the filter string>). Better
> I think would be (at least) three:
>
> * select or filter for things like <fieldname>:<fieldspec (include
> simple regular expressions)>
> * sort
> * limit or count (can't decide if this would be just a number of would
> have some kind of spec to)
>
> Then you can parse the query string, and have specific bits of code
> that select, sort or limit do what they do best, rather than a
> monolith that is confusing.
>
> Set handling could be done as follows (I'm making this up as I go, so
> please suggest something else if this seems wack):
>
> * Unions: use multiple select query paramters, each parameter does
> another select on the full set of tiddlers are the collection being
> filtered/selected from: eg select=tag:blog&select=tag:coment gets all
> tiddlers tagged blog plus all tiddlers tagged comment.
> * Intersections: multiple selection statements in one select paramter:
> select=tag:blog%20tag:comment gets only those tiddlers that are tagged
> both tag and comment.
>
> (One reason I like this idea is that I find it easy to imagine the
> solution: it is still based on generating functions from parsing the
> query string: tag:blog leads to a particular function, whether it is
> doing an intersection or union is based on which set of tiddlers are
> fed to it.)
>
> Obviously someone can come up with some case that this syntax will not
> satisfy but we can do that all day and night, with any syntax. No
> syntax will be perfect. Sometimes you just have to say, "you can't do
> that with this, you'll need to do your own thing."
>
> Some of the shortcomings in this syntax can be overcome by having the
> same bag listed in one recipe multiple times and filtering the output
> of the entire recipe (this is already the common way to create a
> recent changes syndication feed).
>
> Comments?
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TiddlyWikiDev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/TiddlyWikiDev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to