I have table follow that contain user_id and follower_ids in int array:
id | user_id | follower_ids
---|---------|-------------
1 | 1 | {2,3,4}
2 | 2 | {1}
3 | 3 | {1,2}
4 | 4 | {1}
I want to get result like this
user_id | count
--------| -----
1 | 3
2 | 2
3 | 1
4 | 1
how do i run a query?
Thank you.