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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

From two columns to one column?!

Hi

I have a table with columns TeamHome and TeamAway and there is a table called Team which includes all values from the TeamHome and TeamAway columns. What I want to have is that on the frontend is a listbox where I can choose between several teams from TeamHome and TeamAway in one Listbox. How to build a datamodel which can do this without an syn table?

Thankss !

2 Replies
swuehl
MVP
MVP

Maybe like this using CROSSTABLE LOAD:

Fact:

LOAD recno() as ID, * INLINE [

    TeamHome, TeamAway, GoalHome, GoalAway

    1, 2, 2, 0

];

CROSSTABLE (Location, Team)

LOAD ID, TeamHome as Home, TeamAway as Away

Resident Fact;

Team:

LOAD * INLINE [

    Team, Name

    1, Germany

    2, Italy

];

Further reading:

The Crosstable Load

Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Perhaps this tutorial on alternate states helps: Using Alternate States to Select Multiple Values in a List Box with Different Attributes


talk is cheap, supply exceeds demand