Apr 08 2022 10:19 PM
Hi all,
I am new to SQL and I am finding a way to categorise 1 column in my table.
Currently I have 1 column called ID and I want to add 1 column that determine the category of that ID. My desired out is as following:
ID | Category |
1 | a |
2 | b |
3 | a |
4 | a |
5 | b |
The thing is, for 1 category alone, I have like 50+ ID involved, and I have 20+ categories. How do I create a query to simplify this? Many thanks.
Apr 10 2022 02:43 AM