After using the Legacy CSV loader in Opal, we got an error with our data dictionary. Following the suggestions we created a view from the table upload, and imported the data dict. In fact, all the column types were updated correctly. But for some reason, all values in the view were nulified.
At first I suspected it could be because the table/view have unique names, but updating the data dictionary with neither the table nor the view fixed the issue.
Well, the CSV loader is not a legacy one, it is a “built-in” one. The other one is provided by a plugin.
It is not clear to me what you did. Either you set up a table, with the expected dictionary and then import the csv by refering this prepared table; Or you import the csv file like it is and then make a view form it, amending variables with the right value type and the labels if any.
Or you import the csv file like it is and then make a view form it, amending variables with the right value type and the labels if any.
The second one. That’s what we did.
The types were imported correctly but for example a ‘date’ that was in DD-MM-YYYY would be converted to a null. Integer Variables such as 1, 2, 3 were recognized as ‘integer’, but the values were changed to null.
We really encountered this issue when working in a team. There my collaborator would keep getting null values. If i understand correcly, the solution is to ensure that all collaborators have the same View name and that the dictionary is exported from/created for that View (and not necessarily the source table).
You can apply a data dictionary to a view, but do not forget the “script” column that specifies how to transform the values for each variable. If this column is omitted the values will be null (because no derivation script is specified).