Qlik Community

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
QlikWorld 2022, LIVE in Denver CO., May 16-19, 2022. REGISTER NOW TO RECEIVE EARLY BIRD PRICING
cancel
Showing results for 
Search instead for 
Did you mean: 
rofa84
Contributor II
Contributor II

MySQL result as dimension

Hello experts, 

I'm trying to set up a dimension from my SQL query result, and the query is like this,

---------------------------------------------------------------------------------------------------------------------------------------------------------------

SELECT ProdCode,
CASE When Right(ProdCode,5) in ('44762','28399','44762','83615','83728','83733','83777','83779','83800','83801','83803')
THEN 1 else 0 end StarrFlag

---------------------------------------------------------------------------------------------------------------------------------------------------------------

=aggr(only({<StarrFlag={1}>}ProdCode),ProdCode) this is the expression that I used but it's populating with all the code numbers.

I want to use only those numbers for this particular table while other codes from ProdCode is being used for another table. 

Is there a way that I can use set analysis to set up a desired dimension?

Thank you.

0 Replies