Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
hello i should create a composite key with 8 colonne :
select
col 1 , col 2, col 3 , col 4 , col 5 , col 6 , col 7 , col 8
from table
i try col1 & '-' & col2 .... its doesn't work
i try also Field1&'|'&Field2 as Key its doesn't work
Can someone help me to get a solution
May be give a try
Load
Concat(col1, '-', col2, '-', col3, '-', col4, '-', col5, '-', col6, '-', col7, '-', col8) as CompositeKey
From YourTable;
you can not concat 8 colonne .. concat accept only 2 fields ...
In general you could combine multiple fields with an approach like:
col1 & '-' & col2 as Key
at least within Qlik and within a sql-query it should mostly the same. A look in the help from the data-base will list which operators and quotes are allowed for it.
Therefore take a look that the syntax is right and the fields are spelled correctly. If this didn't help you should provide what happens - any error or the result and why the result isn't what you are expecting?