I saw related questions but I really don't understand how to do this.
I have a table name "tbl_image"
id keys image_count
1 0001 1
2 0001 3
3 0001 5
4 0003 6
5 0003 9
I want my output to look like this If I select where the keys = '0001'
output
2
4
And when I select where the keys = '0003'
output
7
8
Thanks in advance.