Ok, so on the property page we would probably need some kind of pseudo code to 
tell SMW how the values are structured? Or should it simply try and group 
numbers and letters itself?
The advantage with telling SMW the structure of the code would be, I guess, 
that you could also do things like returning only the major number, and 
similar. 
Imaging something like this on the property page (N=number, W=capital letter): 
[[Has structure::NW-N]]
And on a content page: [[Has serial number::12A-2]]
Then you could not only sort the values accordlingly but also do things like 
this:
{{ #ask:[[Page]]  |?Has serial number }}      => 12A-2{{ #ask:[[Page]]  |?Has 
serial number#1 }}  => 12{{ #ask:[[Page]]  |?Has serial number#2 }}  => A{{ 
#ask:[[Page]]  |?Has serial number#3 }}  => 2

I have similar cases myself, BTW,but I normally handle that with huge and ugly 
string parsing functions...
/Leo

_______________Leonard wallentinleo_wallen...@hotmail.com@leo_wallentin+46 (0) 
735 - 933 543

> From: katkov.ju...@gmail.com
> Date: Tue, 16 Jul 2013 17:59:48 +0400
> Subject: Re: [SMW-devel] Semantic Extra Property Types?
> To: leo_wallen...@hotmail.com
> CC: semediawiki-devel@lists.sourceforge.net
> 
> well it's an old problem of ours: in enterprise wikis you always have
> such strings. I consider it a new type because of special way of
> sorting.
> 
> For example the consider the identifiers of some objects in a
> government database:
> 1A-1, 2A-1, 3A-1, ... , 10A-1, 11A-1
> 
> If you store them in a string they will be sorted like this
> 1A-1, 10A-1, 2A-1, 3A-1, ... ,  11A-1
> 
> The workaround solution looks too ugly for me: it's storing all the
> parts of my identifier in a different properties like:
> [[ID first number::10]][[ID letter::A]][[ID second number::1]]
> This way we won't be able to show the whole ID in a standard result
> formats (like broadtable) as a one whole entity and should constantly
> rely on a format=template.
> 
> Other than sorting this type should work as a simple string.
> -----
> Yury Katkov, WikiVote
> 
> 
> 
> On Tue, Jul 16, 2013 at 5:07 PM, Leonard Wallentin
> <leo_wallen...@hotmail.com> wrote:
> > Can you elaborate a bit on the "number-string" thing; How would you want it
> > to work?
> >
> > /Leo
> >
> > _______________
> > Leonard Wallentin
> > leo_wallen...@hotmail.com
> > @leo_wallentin
> > +46 (0) 735 - 933 543
> >
> >
> > ________________________________
> > From: katkov.ju...@gmail.com
> > Date: Tue, 16 Jul 2013 07:25:21 +0400
> > Subject: Re: [SMW-devel] Semantic Extra Property Types?
> > To: leo_wallen...@hotmail.com
> > CC: semediawiki-devel@lists.sourceforge.net
> >
> >
> > Hi Leo!
> > The duration would be good. I usually need the hybrid "number-string" type
> > with complex sorting for values like "2-5 years" or "2A-4/323"
> > -----
> > Yury Katkov, WikiVote
> >
> >
> >
> > On Mon, Jul 15, 2013 at 9:50 PM, Leonard Wallentin
> > <leo_wallen...@hotmail.com> wrote:
> >
> > Hello,
> >
> > we already have extensions like Semantic Result Formats, Semantic Forms
> > Input and Semantic Extra Special Properties to gather useful but less common
> > formats. Would it make sense to create a similar collection of extra types
> > (possibly moving less used existing ones, like temperature, from SMW core to
> > the extension)? Are there some types that are commonly requested?
> >
> > As for me, I'm missing duration (like [[Cooking time::1h]] or [[Personal
> > best::01:09.48]]). I realize that localization will be difficult for that
> > one, but at least ISO 8601 (PT6M4S) and a few commonly occuring formats
> > (08:42.00, 8時42分, 8 h 42 min, etc) might be possible to implement. Are there
> > other possible types that are missing out there (that someone actually
> > needs)?
> >
> > /Leo
> >
> > _______________
> > Leonard Wallentin
> > leo_wallen...@hotmail.com
> > @leo_wallentin
> > +46 (0) 735 - 933 543
> >
> > ------------------------------------------------------------------------------
> > See everything from the browser to the database with AppDynamics
> > Get end-to-end visibility with application monitoring from AppDynamics
> > Isolate bottlenecks and diagnose root cause in seconds.
> > Start your free trial of AppDynamics Pro today!
> > http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
> > _______________________________________________
> > Semediawiki-devel mailing list
> > Semediawiki-devel@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/semediawiki-devel
> >
> >
                                          
------------------------------------------------------------------------------
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
_______________________________________________
Semediawiki-devel mailing list
Semediawiki-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/semediawiki-devel

Reply via email to