0
I have the following appointment:
SELECT UPPER(admatribuido) AS [admAtribuido],
Count(admatribuido) AS [quantidade_admAtribuido]
FROM ##tmp
WHERE Month(dataabertura) = Month(Getdate())
AND Year(dataabertura) = Year(Getdate())
AND admAtribuido <> 'null'
GROUP BY admatribuido
That brings me the following return:
I would like to concatenate a dash " - " and the quantity_admAtributed in the admtributed, for example:
admAtribuido | quantidade_admAtribuido
ANA PAULA SOARES - 100 | 100
If you are using Sql Server 2016 there is tsql
Contat
, will look something like:SELECT CONCAT(UPPER(admatribuido), '-' ,Count(admatribuido))...
– Marconi