When importing data from csv, allow to set a static field value (not present in source data)

Use case:
Importing data from different clients, each uses a different currency. Each client is a difference CSV. Ideally I can set the currency for that import when I’m importing that CSV.

The other options are either importing then setting. Or fixing it in the csv before importing.

What does this mean? A currency field is just a number field with some extra formatting, and the formatting is the same for every entity in the db.
If you’re importing USD amounts one minute and the importing EUR amounts the next, surely you need to import into different fields each time.

In my scenario it is a relation to the Currency database from the Currency Exchange integration.

Not if you’re specifying the currency on another field!

So your example is a specific case of a more general need of wanting to import a CSV file whilst setting a fixed value for a to-one relation field (which is otherwise not present in the csv data) right?

Exactly, but the need is not only for a to-one relation field, but any field.

So generically, you want to be able to import data from CSV and have Fibery set the value for a field not present in the data.

Exactly. Sometimes when exporting data from a provider, you can only do it one X at a time (per client, per currency, per whatever). Then this value is not visible in the CSV as it is the same for all of then, this is the use case a feature like this would be helpful.

Another use case is tracking imports. Not super needed because the Creation Date tells you when things were created, but might be useful in some cases. So you have an “Import” database, and link to a new entity every time you import, for example.

Thx. I’ve renamed the topic for clarity

1 Like