Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 
					
				
		
Hello,
I've the following table:
    
| FIELD A (NOKEY) | FIELD B (NONOTA) | FIELD C ( RIGA) | 
| LI11703020120117000000001 | XXX | 10 | 
| LI11703020120117000000001 | YYY | 20 | 
| LI11703020120314000000010 | AAA | 10 | 
| LI11703020120314000000010 | BBB | 20 | 
| LI11703020120314000000010 | CCC | 30 | 
The concatenation of the FIELD B should follow the order of the FIELD C for the distinct value of the FIELD A
How do I give this indication to the function used? The function used is the following:
aggr (Concat (DISTINCT NONOTA, ''), NOKEY)
But I get a concatenation unordered for the field B and it's wrong.
I would like to have the following string in output AAABBBCCC while I get the following string AAACCCBBB.
Thanks.
 
					
				
		
 marcus_sommer
		
			marcus_sommer
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		concat() had a third parameter for sorting but it must be a numeric one.
- Marcus
 
					
				
		
Hi,
please try....
=NOKEY&NONOTA&RIGA
it will concat and all field.
 
 
					
				
		
It's possbile to use a name of a field as a third parameter ?
If not, how can I order for the FIELD C ?
I do not understand what is the logic with which the strings are concatenale.
 
					
				
		
I would concatenate only the value of the FIELD B for the distinct value of the field A order by FIELD C.
 
					
				
		
could you please text an example on you real data which you posted, so I can understand
 
					
				
		
This is a summary of the table that I read
| FIELD A (NOKEY) | FIELD B (NONOTA) | FIELD C ( RIGA) | 
| LI11703020120117000000001 | XXX | 10 | 
| LI11703020120117000000001 | YYY | 20 | 
| LI11703020120314000000010 | AAA | 10 | 
| LI11703020120314000000010 | BBB | 20 | 
| LI11703020120314000000010 | CCC | 30 | 
I would have a result like this
LI11703020120117000000001 XXXYYY
LI11703020120314000000010 AAABBBCCC
In same case I obtain this result:
LI11703020120314000000010 AAACCCBBB
Thanks
 
					
				
		
Hi,
I have used same formula, which you have applied and it is working fine.
=aggr (Concat (DISTINCT nota, ''), nokey)
please find the attachment.
 
					
				
		
 marcus_sommer
		
			marcus_sommer
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Try: Concat (DISTINCT NONOTA, '', RIGA)
- Marcus
 
					
				
		
Hi Rakesh, I've tried bue the problem is still present.
I don't understand how can I attach a file in the discussion, if is possible I attach a file that explain the problem.
