I have an external system sending objectname, fields names of it and DML operation type to perform i.e., insert or update or upsert.
Insert can be done easily.
Given that external system sends records with fields specified to update/upsert (except Id as they do not have the reference),should I take the following approach or is there a better way to do it.
for every record sent, query and fetch by filtering with these fields , build a map of Id, that object updated with new values and final upsert or is there a better approach