Uploads create or update
Every upload works row by row:
If a row's key matches an existing record, the record is updated.
If it doesn't, a new record is created.
See Bulk upload overview for the key used on each tab.
Blank cells don't erase values
Leaving a cell blank in a re-upload does not clear the existing value. Blank means "leave it as is." This lets you upload only the columns you want to change, but it also means you can't remove a value by blanking it.
Deleting records
To delete records, add a column named action as the last column on the tab and enter delete on each row you want removed. Leave action blank on every other row.
ref_id | label | category | active_at | retired_at | facility | action |
old-site-electricity | Old Site - Electricity | s2.1 |
|
| old-site | delete |
denver-office-electricity | Denver Office - Electricity | s2.1 |
|
| denver-office |
|
The action column works on every tab. Any value other than blank or delete causes an error.
Note that deleting an activity cascades to all related consumption and custom emission factors records, and deleting a tag cascades to all related metric records.
Renaming a record
Because records are matched by identifier, changing a ref_id or tag name in your file creates a new record and leaves the old one in place. To rename:
Upload the record under its new identifier.
Move any related data, such as consumptions, to the new identifier.
Delete the old record with
actionset todelete.
Duplicate keys in one file stop the upload partway
If the same key appears twice in one file, the upload stops at the second occurrence. Rows before that point are saved, and rows after it are not. Check for duplicate keys before uploading. If this happens, fix the duplicate and upload the full file again. Rows that were already saved will simply be updated.
Exporting, editing and re-uploading
Exporting your data, editing it in Excel and uploading it again is a good way to make bulk changes. Keep identifiers exactly as exported, and watch for Excel changing values automatically, for example removing leading zeros from ZIP codes or reformatting dates.
