I have a hstore column in my postgresql database. Each row of the database has a different number of keys/values in the hstore-column. How can i get the number of keys/values for each row?
select hstore_column,
array_length(akeys(hstore_column), 1) as num_keys
from the_table