Yes, I totally understand what you want and my explanation will give you exactly what you need.
Like I said you either use a tool like ESX, or vRP or whatever. Or you have to get the id yourself. If you do not have a framework in place and you do not want to create a lookup table with the data on Player join, your best bet is I think to loop through all players connected and send them a message.
I will write this in here, like always. So keep an eye open for typos:
local result = MySQL.Sync.fetchAll("SELECT identifier FROM users WHERE `group` = 'superadmin'")
if result then
local lookupTable = {} -- I create a temp lookUpTable, because its the best datastructure for the job
for _, playerId in ipairs(GetPlayers()) do
lookupTable[GetPlayerIdentifiers(playerId)[1]] = playerId -- check this. I believe GetPlayerIdentifiers(playerId)[1] is the identifier from your database
end
for k,v in pairs(result) do
TriggerClientEvent('chat:addMessage', lookupTable[v.identifier], {
template = '<div class="chat-message"> - <b> aaaaaa </b> </div>',
})
end
end
CancelEvent()