Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik and ServiceNow Partner to Bring Trusted Enterprise Context into AI-Powered Workflows. Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
Lucky1
Creator
Creator

How to sort by - symbol

Hi

countryacronym field with values

US.ICE-FUTURES

US.Future

US-Miam

US.mik

 

I want to sort this by symbol like (.) should be 1st position  and _ should be last

Need my output like

CountryAcronym--this is my field name

US.Future

US.mik

US.ICE-FUTURES

US-Miam

 

 

Labels (5)
10 Replies
vinieme12
Champion III
Champion III

updated solution, slight change in logic

 

Load
Ticker
,if(index(Ticker ,'-'),2,1)&Ord(upper(Ticker))&Ord(coalesce(subfield(upper(Ticker),'-',2),subfield(upper(Ticker),'.',2))) as Ticker_Sort_Order
inline [
Ticker
US.FR
US.MGE
US.NF
US.OC
US-IL.IDFP
US.CBO
US.CM
US.DTC
US.FINR
];

vinieme12_0-1686555249995.png

 

 

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.