12 Posts
jfquestiaux
4 years ago
6
Topic

Hi,

I have a list displaying the values of an SQL request (the count of some elements). I can sort by all the other elements in the list but not on this element, whether I set the type in "text" or "numeric" (it's actually numerical values). Is it possible to sort such a type of element?

Get a Book for SEBLOD
4229 Posts
Kadministrator
4 years ago
5
Level 1

Hi,

exactly what type of the filed you would like to use? For sorting you can use any normal form field (text, select etc), but ofc you can't use e.g. list field or similar

12 Posts
jfquestiaux
4 years ago
4
Level 2

Thank you for your answer but I'm sorry to not understand what you mean by "ofc you can't use e.g. list field or similar". The field I try to sort is a "SQL request" type: 

I have a list of "things" - each activity has a certain amount of "features". The SQL field counts how many "feature" each "thing" has and returns the result as a number in the list of "things". This works fine.

I can order (asc or desc) this list by the name of "things" but ordering by the amount of "features" does not work, whether I set the type "text" or "numerical".

4229 Posts
Kadministrator
4 years ago
3
Level 3

Hi, there is no SQL request field type, do you use one of this fields? https://www.seblod.com/store/extensions/19162

12 Posts
jfquestiaux
4 years ago
2
Level 4

Yes, it is actually "SQL Query" (part of the "Processing" group in the list of types) and I did buy the "SQL pack" so I assume that's what it is.

12 Posts
jfquestiaux
4 years ago
1
Level 5

Friendly bump.

1283 Posts
Bucklash
4 years ago
0
Level 6

Hi

In all search and list situations i always put debug on.

I don’t know if the search will recognise your sql query field’s value... you will find that out :)

Get a Book for SEBLOD