Exporting Data without Lookup?

General Server Forum (Inactive)
Exporting Data without Lookup? millerjw4  2019-08-08 14:04
Status: Closed


I am currently trying to create a study in LabKey. The study data is exported from a number of REDCap projects, which use integer codes for categorical fields. I am uploading the data in this integer-coded form, then using lookup tables (1: 'Male', 2: 'Female' 3: 'Other', etc) to display the text values for these fields in the data grid in an effort to make the data more readable. However, I would like for users to be able to export the data in its original, integer-coded form for use in analysis software. When I explore LabKey's export options, it seems to only be able to export the text lookup, without the ability to go back to the original integer codes. I'm not sure if I'm missing something, but it would be really nice to have that functionality without needing to rely on some external transformation to restore the original codes from REDCap.

Thanks for any assistance,

Jon (LabKey DevOps) responded:  2019-08-22 23:01
Hi Jonathan,

When you export a grid, you're basically getting the data as you see it (WYSIWYG). So if you need to get the underlying value from a lookup, you will need to edit the grid view to expose that column to show those values.

So for example, if you edit your grid view by going into the Customize Grid section, you should see your specific field that has the lookup attached to it and the + sign next to it to allow you to expand the field to show you what fields are tied to that lookup. From there, you can select the appropriate primary key column from your lookup to have that be presented in your grid view, which will in-turn show the integer column you want to actually show.

For more details on updating the grids, please check out the following doc: