How to copy a key value from one doc to other doc from same bucket

UPDATE Bucket_Name a SET codes = (SELECT RAW codes FROM Bucket_Name b WHERE type = “air” AND package= “Extra”)[0] WHERE type = “air” AND package = “Blue”;

I was able to execute , with above query

You can use one you suggested.

Give the example of document and output. What is Join criteria.