Use UPDATE … FROM when new values come from a reference table. The join condition selects the match, while additional conditions limit which target rows change.
A lookup table
CREATE TEMP TABLE Food (Code VARCHAR, Grp VARCHAR, Quantity INT);
INSERT INTO Food VALUES
('Apple', 'Fruit', 44), ('Banana', 'Fruit', 1),
('Tomatoes', 'Vegetables', 8);
CREATE TEMP TABLE GroupLookup (ID VARCHAR, Description VARCHAR);
INSERT INTO GroupLookup VALUES
('A001', 'Fruit'), ('A002', 'Vegetables');
Apply the update
UPDATE Food
SET Grp = g.ID
FROM GroupLookup g
WHERE Food.Grp = g.Description
AND Food.Quantity >= 3;
Apple becomes A001 and Tomatoes becomes A002. Banana keeps its original group because its quantity is below three.
Keep the target column on the left of SET unqualified, as in the Snowflake UPDATE syntax: Grp, not Food.Grp.
Make matching deterministic
Each target row should match one source row. If the lookup contains conflicting matches, resolve them using an explicit business rule first. You can also make Snowflake reject ambiguous updates:
ALTER SESSION SET ERROR_ON_NONDETERMINISTIC_UPDATE = TRUE;
Preview your join with a SELECT before running the update on real data.