Column metric must be of type UNKNOWN, TEXT, VARCHAR, CHAR. metric column name: metric type: INT4 but datatype is int64

i’m trying to create pie chart for showing traffic based on port number.
but i’m getting this error

how can i fix this?

problem solved by changing the above query to this:

now() AS “time”,
cast(port_dst as text) as “metric”
from acct_v9
where ip_dst = ‘’ AND stamp_updated >= now() - interval ‘10 minute’
group by 1 , port_dst
order by sum(bytes) DESC
limit 5;