cancel
Showing results for 
Search instead for 
Did you mean: 

MDO select query: how to control sort order using parameter

Former Member
0 Kudos

Hi experts, is there a way of controling the sort order of an MDO select query using some parameter?

I was thinking about using some statement like CASE [Param.1] WHEN 'abc' THEN [ORDER_NO]...END in sort section of the query but it is not working.

Of course I colud go for various select queries...but I am wondering if it can be done using only one?

Any ideas?

Thanks for any help

Accepted Solutions (1)

Accepted Solutions (1)

swaroop_anasane
Active Contributor
0 Kudos

Hi Marco,

Yes this can be achieved dynamically using SortExpr under dynamic link assignment in MDOAction block if you are using a transaction to call it.

Please check below thread:

Or else, this [Param.1] thing should work as well provided it doesn't get the logic part in it, just pass the columns names separated by comma. Haven't tried it though, will check it for you.

Best Regards,

Swaroop

Former Member
0 Kudos

Thanks swaroop!

Answers (0)