how does CSV import deal with database join elements?

Status
Not open for further replies.

p38

Active Member
Before I spend some time on this section for clients, I would like clarity on how the CSV import deals with database joins?

Will it handle the import correctly, in other words, check the field value is in the lookup list, and store the linked "id"?

Same goes for lists and checkboxes?

paul
 
The answer is "it does it's best". But no, it won't look up "field values" in existing joined table. It'll only try and use any existing FK's you give it in the imported data. If you don't provide FK values for the linked table data, it'll just insert a new row, and link the new key for that. if you provide FK values, and are importing in overwrite mode, it'll update the existing rows.

Well I guess it depends what you mean by "check the field value is in the lookup list". But unless you are referring to the Foreign Key (FK) value that is used to join the tables, then no.

With anything to do with CSV import export, the best thing to do is insert some test data in your list(s) in Fabrik, do an export, which includes raw data, and look at the exported data. Then model your imported data on that.

-- hugh
 
Oh, hang on, you said "join elements".

So the answer is "No".

You need to provide the "value" (key) as raw data, not the "label". Same is true for any element type that has the concept of a "value" and a "label". We don't attempt to reverse engineer the value from the label.

-- hugh
 
Status
Not open for further replies.
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top