Queries and Result Ordering

Topics related to the LSPS Academy.
mjamaluddingari
 
Posts: 6
Joined: Tue May 06, 2014 9:18 pm

Queries and Result Ordering

Thu Sep 17, 2015 11:27 pm

Hi,

I have completed the Queries and Result Ordering training from the academy and it is so much helpful. It says "In the next tutorial, we will populate the results from the table". I was just wondering where I can find that "next tutorial". Anyway, my related question to the video is how do I do the ordering based on values from a result set. For example, let's say the enumeration 'Genre' has a list of literals and I wanted to do the ordering based on values. I want the order to be mystery, horror, fiction, nonFiction. Generally, using sql query I would use
Code: Select all
ORDERY BY CASE GENRE WHEN mystery then 1
                     WHEN horror then 2
and so on..

How do I specify in this case? Appreciate your help.
Attachments
ordering.PNG
ordering.PNG (7.16 KiB) Viewed 1396 times

mjamaluddingari
 
Posts: 6
Joined: Tue May 06, 2014 9:18 pm

Re: Queries and Result Ordering

Fri Sep 25, 2015 5:57 am

Is it the wrong place to post or the question is invalid?

Radovan Cervenka
 
Posts: 48
Joined: Mon Feb 27, 2012 2:47 pm

Re: Queries and Result Ordering

Fri Sep 25, 2015 10:07 am

In LSPS queries, it is impossible to specify "ORDERY BY CASE" style of ordering. However, you can specify SQL native query or Java function for querying DB. How urgent is this feature for you? I'm asking in order to access its urgency for creating a feature request, if you want to have it in LSPS.

mjamaluddingari
 
Posts: 6
Joined: Tue May 06, 2014 9:18 pm

Re: Queries and Result Ordering

Fri Sep 25, 2015 4:53 pm

Thank you for the response. We would definitely love to have this feature in LSPS queries. And at my company it is always 'ASAP'. :D

Radovan Cervenka
 
Posts: 48
Joined: Mon Feb 27, 2012 2:47 pm

Re: Queries and Result Ordering

Mon Sep 28, 2015 10:43 am

Feature request has been created and preliminarily planned for LSPS 3.2 (1st quarter 2016).

Return to LSPS Academy

Who is online

Users browsing this forum: No registered users and 1 guest