Grooper 21.00.0082 is available as of 12-12-2023! Check the Downloads Discussion for the release notes and to get the latest version.
Grooper 23.00.0044 is available as of 06-20-2024! Check the Downloads Discussion for the release notes and to get the latest version.
Grooper 23.1.0026 is available as of 09-16-2024! Check the Downloads Discussion for the release notes and to get the latest version.
Grooper 24.0.0012 is available as of 10-10-2024! Check the Downloads Discussion for the release notes and to get the latest version.
Exporting Fields in a DataModel that also contains a DataTable.
strotelli
Posts: 42 admin
How do I choose a DataModel as a Data Element in an Grooper Database Export step when my DataModel also contains tables?
Tagged:
0
Best Answer
-
RandoCalrisian Posts: 195 adminYou need to have separate Export activities.
In my example, I'm using DatabaseExport.
One DatabaseExport's DataElement will be mapped to the DataTable object and be mapped to a table in a SQL database.
This DataModel also contains DataFields, and they are in a DataSection using a generic RegEx pattern of:
.*
This pattern simply lets the DataSection reference the whole document, as it is a requirement for a DataSection to have an extractor.
The second DatabaseExport activity's DataElement will be mapped to the DataSection. Each of the DataFields within this section will, as a result, be mapped to fields in a separate SQL table.
Randall Kinard
rkinard@bisok.com5
Answers
The example I listed above is a specific case where the DataTable has to be mapped separately from the listed DataFields because the ContentModel contains multiple DataTables, and, the DataFields are not higher in the hierarchy than the table is.
In the example I have below, one could map the DatabaseExport step's DataElement property to the table01 DataTable. As a result, the DataFields of table01, and all DataFields that are higher in the hierarchy than the DataTable, can be mapped in one DatabaseExport step. However, were another DataTable to exist in this ContentModel, a separate DatabaseExport step would have to be used for it.
rkinard@bisok.com