Do empty input fields overwrite destination values?

Hi Make friends!

Can anyone tell me how Make treats incoming blank values when mapped to update a destination object/record/field?

Example Scenario:

  1. John submits a form and includes his phone number

  2. His phone number gets written to a database by Make

  3. John submits the form again and does not include his phone number

  4. In the database, his phone number gets ____________ by Make?

What happens in step 4? Does his phone number get cleared? or does it still exist because the incoming data was empty?

I’m aware that there is an ifempty() function, but this only applies to the destination field and not the incoming data if I’m not mistaken.

Hi @SashaSosin,

Welcome to the Make community! When using the Update a Record module for the Data Store, values of a record are only overwritten if a value is mapped. If there is no value mapped in the field (that means also no ‘null’ or ‘emptystring’, nothing is overwritten.

For arrays, it works a little different. Here you have the option to overwrite an existing array in the record:

Cheers,
Henk

2 Likes

Thanks @Henk-Operative! I understand that no mapping means no overwriting, but what if it is mapped and the incoming data is sometimes empty. The same logic applies?

Good question, in that case: also nothing is overwritten.

If the input (mapped value) is empty, then the field is empty and there will not be an update for that value of the record.

3 Likes

Thank you! I just created a test scenario and confirmed that what you said is correct. I probably should have done that to begin with, but hopefully this might help someone using a search engine in the future!

3 Likes

Well, that is the power of this community indeed. I am glad you have your answer! :slight_smile:

2 Likes