Select to view content in your preferred language

Query Widget - Results sorted Alphabetically or Numerically

3225
19
10-07-2010 11:57 AM
BrianKratcha
Regular Contributor
Is there an easy way to have my Query Widget return results sorted alphabetically or numerically?  Right now the results come back sorted randomly. 

Thanks,

Brian
Tags (2)
0 Kudos
19 Replies
JonBeets1
Emerging Contributor
If someone already has this done can you please send me the compiled widget?...

It's also interesting that a sorting feature wasn't built into the widget originally. No one wants to scroll through a 100 result query that's not sorted... 😉

Jon Beets

Jon.Beets@us.af.mil
0 Kudos
BrianKratcha
Regular Contributor
Is anyone else having problems getting the above to work in 3.0?
0 Kudos
MelissaPrindiville
Emerging Contributor
I am having a problem with the code in version 3.  Any ideas on how to fix it?  No errors just doesn't sort.  I had it working in previous versions.
0 Kudos
MarkHuffman
Deactivated User
I tried this code for the first time in a version 3 viewer. I updated it to match changes between 2 and 3. I confirm that, although no errors are thrown, no sorting is done either. Can whoever has adapted the code successfully please post? Thanks.

Mark
0 Kudos
daveespinosa-aguilar
Emerging Contributor
also having same issues with 3... no errors, still queries, doesn't sort. looking into it further...
0 Kudos
SerenaO_Connor
Emerging Contributor
Just wondering has this been sorted for 3.0

I have a list of buildings which I need to show alphabetically and just wondering what code I should add.

<?xml version="1.0" ?>
<configuration>
    <layer>http://localhost:6080/arcgis/rest/services/UCC/Buildings/MapServer/0</layer>
    <query/>
    <titlefield>Name</titlefield>
    <linkfield>Name2</linkfield>
    <refreshrate>3</refreshrate>
    <zoomscale>15000</zoomscale>
    <fields all="false">
        <field name="Name" alias="Name"/>
    </fields>
</configuration>

Any help would be much appreciated.
S
0 Kudos
BrianKratcha
Regular Contributor
So has anyone had any luck?
0 Kudos
MarcWeinshenker1
Regular Contributor
For anyone following this thread, I found the same problem when converting to Flex Viewer 3.0 and I  have filed a support incident to see if this can be addressed.

[edit -- solution posted here http://forums.arcgis.com/threads/67832-Query-Widget-3.0-sort-results?p=236775&posted=1#post236775 ]

Marc
0 Kudos
JohnGregorovic
Deactivated User
Worked great for me, thank you for you help.
0 Kudos
HeatherGonzago
Esri Contributor
0 Kudos