0

I am trying to populate null values. Using the ParcelID I can see that the data is there, just some columns are empty. This is the code I have so far:

UPDATE `utility-binder-333917.housing_data.nashville_housing`
SET PropertyAddress = IFNULL(a.PropertyAddress, b.PropertyAddress)
FROM(
SELECT a.ParcelID, a.PropertyAddress, b.ParcelID, b.PropertyAddress
FROM `utility-binder-333917.housing_data.nashville_housing` as a
JOIN `utility-binder-333917.housing_data.nashville_housing` as b
ON a.ParcelID = b.ParcelID
AND a.UniqueID_ <> b.UniqueID_)
WHERE a.PropertyAddress is null

Can anyone tell me what the error is please? Thank you.

0 Answers0