I have a table, we’ll call it users.
id username type
The type field is a two character type, so each user either has US, MO, AD. Not sure why the original developer did this, but I cannot change this method, unfortunately.
1 mike US
2 Tim AD
3 mark MO
Instead of returning US, AD… etc types in Access, I’d like the query to replace the US with USER, replace MO with MODERATOR, and replace AD with ADMIN.
Is this possible?
Kind of like SELECT * FROM USERS and then if statements within Access (if US, then USER). Not sure how to proceed?
You can create a table for the US to USER, MO to MODERATOR etc mappings and use it in a join.
A lot easier to maintain, extend (i.e. different languages) than hard-coding with the drawback that you need to maintain your mapping table.