How to insert new values into dictionary/table whilst keeping current values in them

How to insert new values into dictionary/table whilst keeping current values in them?

local crewDetails = {
[“Members”] = {DataStore:GetAsync(key), }
}
table.insert(crewDetails.Members, {Player.userId, Player.Name, “Member”, Player.Data.Level.Value, Player.Data.Bounty.Value})

Can you please give more context as to what you’re trying to do in the code?

Basically I have a system where people can create their own crew/group in the game.

The crew members details save into a dictionary and it works perfectly fine, it’s just that I want new members to be able to join that dictionary with keeping the current values or members in them.

So your data structure follows this format?

{
    members = {
        player1 = player1Data,
        player2 = player2data,
        ...
    }
}

You would have to unfortunately insert them one by one. U less there is a way to join two tables together that I don’t know of.

Yes just need to keep all other members there from the datastore.

So what are you trying to do with DataStore:GetAsync(key)? Is this the data for an individual player, or does a single data-store key store the data for all players?

It’s data for all players depending on what the group ID is.
so

local key = “Crew”…Crew.Name