ceumicrodata / mETL

mito ETL tool
161 stars 41 forks source link

defaultValue should be named setValue, constantValue or simply value #14

Open e3krisztian opened 11 years ago

e3krisztian commented 11 years ago

I have tried to solve #13 with adding defaultValue: '' to every not null field, but to my surprise it forced those fields to be null, even if there was data in the input for the field.

The name defaultValue implies to set the value when none was present - either the field is new (not in the input) OR the input field is there, but its value is NULL).

defaultValue is better named setValue, constantValue or simply value, as it is replacing the value unconditionally with the one specified.

Probably it is worth having both value and defaultValue as they are used in different situations.