Any Idea to do this expression?

I would like to set up a column that when a user pick certain category e.g: civil, mechanical or electrical. It will then generate a uniqueID that will show like

if civil → generate QW C 01

if mechanical → generate QW M 01

if electrical → generate QW E 01

I know that we could use concatenate and do that but since the problem is that the number QW E ‘01’, I usually used row number as references but since in this case I would want it to be continuously from the same category, I am not sure how to do that. Any idea?

As your search the forum for solutions to generate sequential numbers quickly reveals there is no guaranteed way to generate unique sequential values when more than one person uses the app concurrently and the use of serial numbers are ‘STRONGLY’ discouraged.

Having said that at your own you risk you can use, as an example, a formula like this

& (COUNT(FILTER(“table name”, [category] = [_THISROW].[category])) + 1)

https://www.googlecloudcommunity.com/gc/Tips-Tricks/Generating-Sequential-Numbering-Using-App-Script-Tasks/m-p/451776