Feb 02, 2023

Removing fields

Dromo recently added the ability to remove fields, which allows you even more power and flexibility when defining your schema.

One common example of when you would want to remove fields is when you are concatenating two fields together. You could be importing a "full name" field, but your customers have files with separate first name and last name columns. In this case, you could define first name and last name columns in your schema, which your customers would match to their existing columns. Then, using hooks, you can concatenate the data in these columns into a new virtual field for the full name.

Previously, you would be stuck now with three columns – the imported first and last name columns, and the full name column which you will ultimately import.

Now, you can simply call removeField with the old first and last name columns and continue on in normalized data bliss!

As always, you can find more info in our docs.

© 2024 Dromo

Subscribe