Thanks Mike,

so basically i am trying to do is simulate a ticketing tool.. , and assign 
prioritys to tiddlers i am using as tasks ,  2 criteria(severity , impact) 
or more  that add up to a given priority/ranking , 

so tiddler A is called " archive data" 

field x is  "severity" and  has value 1111111
filed Y is  "impact"  and has value 111111111
Field z is "priority" and  has value {{!!severity}}{{!!impact}} --> 
translating to 1111111111111111 

tiddler b is called "restart server"

field x is  "severity" and  has value 11
filed Y is  "impact"  and has value 11111111111
Field z is "priority" and  has value {{!!severity}}{{!!impact}} --> 
translating to  1111111111111 



they also have another field "status" which can be either " In House " or " 
With Vendor" , so thats another 4th field that will hold any of these 2 
values .

then...

<$list filter= 
"[status[In House]][status[With Vendor]]+[sort[priority]]">



Now ,The reason i am using ones in the field values (ie 11111) is because , 
i understand you cant do math in fields .. which is another problem ..

but then my thinking was ,i run a filter on all tiddlers which has "In 
house " or "With Vendor " in the status field values  
[status [In House]][status[With Vendor]] 

then sort them using the priority field , and that should sort the tiddlers 
with the higher ranking at top, and thats when i realized the sorting doesn 
work , hence this post.

i have few questions

if i understood correctly you are saying this can be done using tags 
instead ? 
so can it be done using field instead (so instead of  [tag[sortbyfield], 
could it be [status [In House]?
also how can i view the outcome of the mathematical operations?

and finally , now that you know what i am after , is there a better way of 
doing all this ?





On Tuesday, May 18, 2021 at 4:41:19 PM UTC+2 [email protected] wrote:

> For instance, in your specific example you could use a filter like 
> [{!!x}multiply[10]add{!!y}] in the sortsub for your list of tiddlers 
> containing x and y ... you don't need a z field for this particular use.
>
> So if you had a bunch of tiddlers tagged with "sortbyfield" you can do:
>
> \define ssfilter() [{!!x}multiply[10]add{!!y}]
>
> <$list filter="[tag[sortbyfield]sortsub:integer<ssfilter>]"/>
>
> This works for your particular example that you provided because you can 
> do math in the filter. Not sure how easy it would be in the general sense.
>
> /Mike
>
> On Tuesday, May 18, 2021 at 9:03:46 AM UTC-3 Michael Wiktowy wrote:
>
>> Not exactly what you want but if you can express your combination of 
>> field x and field y as a filter expression, you should be able to use 
>> sortsub.
>> /Mike
>>
>>
>> On Monday, May 17, 2021 at 10:45:20 PM UTC-3 [email protected] 
>> wrote:
>>
>>>
>>> Hi ,
>>>
>>> is it possible to sort transcluded /referenced values?
>>>
>>> so i have tiddler 1 which has 3 fields ,field x , field y and field z 
>>>
>>> field x = 1
>>> field y = 2
>>> field z=  {{!!field x}}{{!! field y}}  --> which translates to "12"
>>>
>>> Now i have the same exact thing happening for 4 or 5 other tiddlers with 
>>> different values for field x and field y , and field z referencing them
>>>
>>> now i am doing a list filter , that lists said tiddlers , and putting a 
>>> sort at the end ..
>>>
>>> so something like <$list filter=  criteria ..... and then towards the 
>>> end     [sort[ field z ]]">
>>>
>>>
>>>  The sort is working, i also used nsort with no luck , so is there 
>>> something i am doing wrong, or referenced values cannot be used as a 
>>> criteria for a sort ?
>>>
>>> Thanks in advance
>>>
>>>
>>>
>>>
>>>
>>>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/624388b5-7991-4172-844b-162c70f40af7n%40googlegroups.com.

Reply via email to