Hi,
I have a data set like this:
col1 , col2 ------------ 'A' , 'aa' 'A' , 'bb' 'A' , 'cc' 'B' , 'dd' 'B' , 'ee'
By using grouping, currently we have aggregate functions like: sum(...), avg(...), etc... But sum(...) is to sum all number values. Do we have any function or any way to 'sum' the String values?
For example, based on the data set above, i want to retrieve the concat string like this (after grouping col1): 'A': 'aabbcc' 'B': 'ddee'
I heard that there is a function called 'group_concat' in mysql, do we have similar function in HQL?
|