• Mixed sorting order

    From Grzegorz R.@21:1/5 to All on Fri Jan 8 07:55:33 2021
    Mixed sroting order
    0 wyświetleń
    Subskrybuj
    Grzegorz R. – zdjęcie profilowe
    Grzegorz R.
    16:54 (1 minutę temu)
    do
    Hi all
    assume You have a database with fields NAME, DATE.
    Is it at all possible to sort the database that one field (NAME) is ascending and other field (DATE) is descending? Like this:
    A 9
    A 8
    A 6
    B 7
    B 3
    B 1
    C 5
    C 1
    Note that NAME may me long and have many different characters
    ?
    Simple order I use is NAME+DTOS(DATE) but then DATE is same direction (A/D) as NAME.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Grzegorz R.@21:1/5 to All on Fri Jan 8 07:56:13 2021
    Hi all
    assume You have a database with fields NAME, DATE.
    Is it at all possible to sort the database that one field (NAME) is ascending and other field (DATE) is descending? Like this:
    A 9
    A 8
    A 6
    B 7
    B 3
    B 1
    C 5
    C 1
    Note that NAME may me long and have many different characters
    ?
    Simple order I use is NAME+DTOS(DATE) but then DATE is same direction (A/D) as NAME.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From dlzc@21:1/5 to ramo***@gmail.com on Fri Jan 8 13:37:48 2021
    On Friday, January 8, 2021 at 8:56:14 AM UTC-7, ramo***@gmail.com wrote:
    Hi all
    assume You have a database with fields NAME, DATE.
    Is it at all possible to sort the database that one field (NAME) is ascending and other field (DATE) is descending? Like this:
    A 9
    A 8
    A 6
    B 7
    B 3
    B 1
    C 5
    C 1
    Note that NAME may me long and have many different characters
    ?
    Simple order I use is NAME+DTOS(DATE) but then DATE is same direction (A/D) as NAME.

    Do you have the descend() function that was in Clipper? https://www.itlnet.net/programming/program/Reference/c53g01c/ng369b2.html

    If so NAME+DESCEND(DTOS(DATE)) should work. Might be problematic on an SQL-like server.

    David A. Smith

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Grzegorz R.@21:1/5 to All on Sat Jan 9 02:41:17 2021
    piątek, 8 stycznia 2021 o 22:37:49 UTC+1 dlzc napisał(a):
    On Friday, January 8, 2021 at 8:56:14 AM UTC-7, ramo***@gmail.com wrote:
    Hi all
    assume You have a database with fields NAME, DATE.
    Is it at all possible to sort the database that one field (NAME) is ascending and other field (DATE) is descending? Like this:
    A 9
    A 8
    A 6
    B 7
    B 3
    B 1
    C 5
    C 1
    Note that NAME may me long and have many different characters
    ?
    Simple order I use is NAME+DTOS(DATE) but then DATE is same direction (A/D) as NAME.
    Do you have the descend() function that was in Clipper? https://www.itlnet.net/programming/program/Reference/c53g01c/ng369b2.html

    If so NAME+DESCEND(DTOS(DATE)) should work. Might be problematic on an SQL-like server.

    David A. Smith
    Hello David
    Yes I have and I do not know how I missed (not found) it...
    DESCEND(DTOS(DATE)) do not work but STR(DESCEND(DATE)) does - that was Karl suggestion due to DESCEND() numerical output.
    Thank You.
    Gregory

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)