How can I convert array to string in hive sql?

Use concat_ws(string delimiter, array<string>) function to concatenate array: select actor, concat_ws(‘,’,collect_set(date)) as grpdate from actor_table group by actor; If the date field is not string, then convert it to string: concat_ws(‘,’,collect_set(cast(date as string))) Read also this answer about alternative ways if you already have an array (of int) and do not want to explode it … Read more

Efficiently repeat a character/string n times in Scala

For strings you can just write “abc” * 3, which works via StringOps and uses a StringBuffer behind the scenes. For characters I think your solution is pretty reasonable, although char.toString * n is arguably clearer. Do you have any reason to suspect the List.fill version isn’t efficient enough for your needs? You could write … Read more

ConcatRelated function in a query

Do not call the Module the same as the function, it can sometimes make things confusing for VBA. Rename the module something like “DatabaseUtils” for instance. Make sure the function is really defined as Public Function ConcatRelated(…, the Public here is important, otherwise the function will not be visible outside the module itself.

Concatenate in jQuery Selector

There is nothing wrong with syntax of $(‘#part’ + number).html(text); jQuery accepts a String (usually a CSS Selector) or a DOM Node as parameter to create a jQuery Object. In your case you should pass a String to $() that is $(<a string>) Make sure you have access to the variables number and text. To … Read more