2023:Data Export (Export Definition): Difference between revisions

From Grooper Wiki
Tag: Manual revert
 
(22 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<blockquote style="font-size:125%">
{{AutoVersion}}
'''''Data Export''''' is one of the '''''Export Types''''' available when configuring an '''''Export Behavior'''''.  It exports extracted document data over a '''Data Connection''', allowing users to export data to a SQL or ODBC compliant database.
</blockquote>


{|cellpadding="10" cellspacing="5"
<blockquote>{{#lst:Glossary|Data Export}}</blockquote>
|-style="background-color:#36b0a7; color:white"
|style="font-size:14pt"|'''FYI'''
|
Prior to version 2021, extracted data was exported using the '''Database Export''' activity.  With the introduction of '''''Export Behaviors''''' in version 2021, this changed.  Data is now exported to databases using the '''Export''' activity and one or more '''''Data Export''''' behavior definitions.
|}


==About==
==About==
 
{|class="download-box"
{|cellpadding="10" cellspacing="5"  
|
|-
[[File:Asset 22@4x.png]]
|style="font-size:14pt; color:#f89420; border: 2px solid #f89420; width:40px"|[[File:Asset 22@4x.png]]
|
|style="border: 2px solid #f89420"|
You may download and import the file(s) below into your own Grooper environment (version 2023).  There is a '''Batch''' with the example document(s) discussed in this tutorial, as well as a '''Project''' configured according to its instructions.
You may download and import the file below into your own Grooper environment (version 2021).  This contains '''Batches''' with the example document(s) and a '''Content Model''' discussed in this article
<br>
* [[Media:Data Export (v2021).zip]]
Please upload the '''Project''' to your '''Grooper''' environment before uploading the '''Batch'''. This will allow the documents within the '''Batch''' to maintain their classification status.
* [[Media:2023_Wiki_Data-Export_Project.zip]]
* [[Media:2023_Wiki_Data-Export_Batch.zip]]
|}
|}


The most important goal of '''Grooper''' is to deliver accurate data to line of business systems that allow the information to be integrated into impactful business decisioning. [https://en.wikipedia.org/wiki/Table_(information) Tables] in [https://en.wikipedia.org/wiki/Database databases] remain, to this day, one of the main vessels by which this information is stored.  '''''Data Export''''' is one of the main ways to deliver data collected in Grooper.
The most important goal of '''Grooper''' is to deliver accurate data to line of business systems that allow the information to be integrated into impactful business decisioning. [https://en.wikipedia.org/wiki/Table_(information) Tables] in [https://en.wikipedia.org/wiki/Database databases] remain, to this day, one of the main vessels by which this information is stored.  '''''Data Export''''' is one of the main ways to deliver data collected in Grooper.
Line 75: Line 69:
We discuss how to create '''Data Connections''', add a new database from a '''Data Connection''', and add a new database table from a '''Data Connection''' in the [[#Configuring a Data Connection]] tutorial below.
We discuss how to create '''Data Connections''', add a new database from a '''Data Connection''', and add a new database table from a '''Data Connection''' in the [[#Configuring a Data Connection]] tutorial below.


{|cellpadding="10" cellspacing="5"
{|class="fyi-box"
|-style="background-color:#36b0a7; color:white"
|
|style="font-size:14pt"|'''FYI'''||We have improved integration with PostgreSQL, Db2, MySQL, and Oracle using the ODBC connection type in version 2021!
'''FYI'''
|
We have improved integration with PostgreSQL, Db2, MySQL, and Oracle using the ODBC connection type in version 2021!


While not fully supported in previous versions of Grooper, you can now connect to these data sources with a '''Data Connection''' seamlessly in Grooper, allowing for full database export operations via '''''Data Export'''''.
While not fully supported in previous versions of Grooper, you can now connect to these data sources with a '''Data Connection''' seamlessly in Grooper, allowing for full database export operations via '''''Data Export'''''.
Line 100: Line 96:
|}
|}


<tabs style="margin:20px">
=== Understanding the Forms ===
<tab name="Understanding the Forms" style="margin:20px">
==== Document 1:  Employee Report ====
===Understanding the Forms===
{|cellpadding=10 cellspacing=5
| style="vertical-align:top; width:40%" |
=== Document 1:  Employee Report ===


The thing to understand about this document is some of its data share a "one-to-many" relationship.
The thing to understand about this document is some of its data share a "one-to-many" relationship.
Line 116: Line 108:


This document is meant to show how to flatten data structures.  While the single instance data is only collected once, it will be reported many times upon exporting to a database table.
This document is meant to show how to flatten data structures.  While the single instance data is only collected once, it will be reported many times upon exporting to a database table.
|
 
[[File:database_export_002.png]]
[[File:database_export_002.png]]
|-
 
| style="vertical-align:top; width:40%" |
==== Document 2:  Personnel Information Report ====
=== Document 2:  Personnel Information Report ===


The second document is essentially one big table of personnel information (name, address, email, phone number and the like).   
The second document is essentially one big table of personnel information (name, address, email, phone number and the like).   
Line 131: Line 122:
This document is meant to demonstrate how to export to multiple tables via one '''''Export Behavior'''''.
This document is meant to demonstrate how to export to multiple tables via one '''''Export Behavior'''''.


{|cellpadding="10" cellspacing="5"
{|class="attn-box"
|-style="background-color:#f89420; color:white"
|
|style="font-size:22pt"|'''&#9888;'''||DISCLAIMER:  The author of this article is not a lawyer.
&#9888;
|
DISCLAIMER:  The author of this article is not a lawyer.


For educational purposes we divided "Personnel Information" into two sets:  "non-PII" and "PII"
For educational purposes we divided "Personnel Information" into two sets:  "non-PII" and "PII"
:&bull;&nbsp; non-PII:  Employee ID, Phone Number, E-mail address, IP Address, Gender, ZIP
* non-PII:  Employee ID, Phone Number, E-mail address, IP Address, Gender, ZIP
:&bull;&nbsp; PII: First Name, Last Name, SSN, Street Number, Street Name, City, State.
* PII: First Name, Last Name, SSN, Street Number, Street Name, City, State.


'''''DO NOT TAKE THIS TO MEAN THIS INFORMATION IS OR IS NOT PERSONALLY IDENTIFIABLE INFORMATION.'''''
'''''DO NOT TAKE THIS TO MEAN THIS INFORMATION IS OR IS NOT PERSONALLY IDENTIFIABLE INFORMATION.'''''
Line 145: Line 138:
PII gets tricky in the real world.  For example, an IP Address would not normally qualify as PII by itself, but could when combined with other personal information.  Please consult your own legal department to determine what data you're collecting is PII and should be protected more securely.
PII gets tricky in the real world.  For example, an IP Address would not normally qualify as PII by itself, but could when combined with other personal information.  Please consult your own legal department to determine what data you're collecting is PII and should be protected more securely.
|}
|}
|
 
[[File:database_export_003.png ]]
[[File:database_export_003.png ]]
|}


<span style="font-size:125%">'''[[#How To|Back to top to continue to next tab]]'''</span>
=== Understanding the Content Model ===
</tab>
<tab name="Understanding the Content Model" style="margin:20px">
===Understanding the Content Model===
The '''Content Model''' provided for this tutorial is named "Example Model - Data Export".  This '''Content Model''' is designed to extract the data for these two different kinds of documents, each represented by its own '''Document Type'''.
The '''Content Model''' provided for this tutorial is named "Example Model - Data Export".  This '''Content Model''' is designed to extract the data for these two different kinds of documents, each represented by its own '''Document Type'''.


{|cellpadding=10 cellspacing=5
==== The Employee Report Document Type ====
| style="vertical-align:top; width:40%" |
 
=== The Employee Report Document Type ===
 
# The "Employee Report" '''Document Type'''' represents our "Employee Report" document.
# The "Employee Report" '''Document Type'''' represents our "Employee Report" document.
#* This is the one we will use to demonstrate flattening a data structure that shares a one-to-many relationship on the document.
#* This is the one we will use to demonstrate flattening a data structure that shares a one-to-many relationship on the document.
Line 172: Line 157:
#* "QTD"
#* "QTD"
#* "YTD"
#* "YTD"
|
 
[[File:2023_Data-Export_02_HowTo_01_01.png]]
[[File:2023_Data-Export_02_HowTo_01_01.png]]
|-
|valign=top|
=== The Personnel Info Report Document Type ===


==== The Personnel Info Report Document Type ====
# The "Personnel Info Report" '''Document Type''' represents our "personnel information" documents.
# The "Personnel Info Report" '''Document Type''' represents our "personnel information" documents.
#* This is the one we will use to demonstrate exporting multiple table structures to multiple databases from a single document.
#* This is the one we will use to demonstrate exporting multiple table structures to multiple databases from a single document.
Line 197: Line 180:
#* "State"
#* "State"
# This set-up uses a single table extractor to collect each row on the document, but reports it to two different '''Data Table''' objects in Grooper (the "non-PII" '''Data Table''' and the "PII" '''Data Table''').  This will ultimately allow us to parse data from these columns, and place the PII related information into a separate database.
# This set-up uses a single table extractor to collect each row on the document, but reports it to two different '''Data Table''' objects in Grooper (the "non-PII" '''Data Table''' and the "PII" '''Data Table''').  This will ultimately allow us to parse data from these columns, and place the PII related information into a separate database.
|
 
[[File:2023_Data-Export_02_HowTo_01_02.png]]
[[File:2023_Data-Export_02_HowTo_01_02.png]]
|}


<span style="font-size:125%">'''[[#How To|Back to top to continue to next tab]]'''</span>
=== Verifying Index Data ===
</tab>
<tab name="Verifying Index Data" style="margin:20px">
 
===Verifying Index Data===


Before the '''Database Export''' activity can send data, it must have data!  
Before the '''Database Export''' activity can send data, it must have data!  
Line 215: Line 193:
A couple of ways to verify its existence are as follows:
A couple of ways to verify its existence are as follows:


{|cellpadding=10 cellspacing=5
 
| style="vertical-align:top; width:40%" |
==== Option 1 ====
=== Option 1 ===
# First, navigate to the '''Batch''' object in the node tree.
# First, navigate to the '''Batch''' object in the node tree.
# From there, click on the "Viewer" tab.
# From there, click on the "Viewer" tab.
# Click the "Open in review page" button.
# Click the "Open in review page" button.
|
 
[[File:2023_Data-Export_02_HowTo_01_03.png]]
[[File:2023_Data-Export_02_HowTo_01_03.png]]
|-


| style="vertical-align:top; width:40%" |
 
Click the "Data Viewer" tab and from there you can review review the data.
Click the "Data Viewer" tab and from there you can review review the data.
|
 
[[File:2023_Data-Export_02_HowTo_01_04.png]]
[[File:2023_Data-Export_02_HowTo_01_04.png]]
|-


|valign=top|
 
{|cellpadding="10" cellspacing="5"
{|class="fyi-box"
|-style="background-color:#36b0a7; color:white"
|
|style="font-size:14pt"|'''FYI'''||Were the document classified (the '''Batch Folder''' assigned a '''Document Type'''), but not successfully extracted (the '''Extract''' activity not applied), the data structure would be present, but the fields empty.
'''FYI'''
|
Were the document classified (the '''Batch Folder''' assigned a '''Document Type'''), but not successfully extracted (the '''Extract''' activity not applied), the data structure would be present, but the fields empty.


At that point the '''Batch Folder''' would have the '''Document Type's''' '''Data Model''' associated to it, but would not have applied its extraction logic to collect values (That's what the '''Extract''' activity is for).
At that point the '''Batch Folder''' would have the '''Document Type's''' '''Data Model''' associated to it, but would not have applied its extraction logic to collect values (That's what the '''Extract''' activity is for).
|}
|}
|
 
[[File:2023_Data-Export_02_HowTo_01_05.png]]
[[File:2023_Data-Export_02_HowTo_01_05.png]]
|}


{|cellpadding=10 cellspacing=5
| style="vertical-align:top; width:40%" |
=== Option 2 ===


==== Option 2 ====
Another means of verifying is to actually view the file created by the '''Extract''' activity and stored in the Grooper repository's file store location.
Another means of verifying is to actually view the file created by the '''Extract''' activity and stored in the Grooper repository's file store location.


Line 252: Line 226:
# Select the JSON file in the files panel.
# Select the JSON file in the files panel.
# Click the "Display file" button.
# Click the "Display file" button.
|
 
[[File:2023_Data-Export_02_HowTo_01_06.png]]
[[File:2023_Data-Export_02_HowTo_01_06.png]]
|-
 
| style="vertical-align:top; width:40%" |
 
A new tab will open in your browser and you will be shown the contents of the JSON file. This is the file the '''Extract''' activity generates when it processes a '''Batch Folder'''.  It serializes all the extracted '''Data Elements'''' values for the document's '''Data Model'''.
A new tab will open in your browser and you will be shown the contents of the JSON file. This is the file the '''Extract''' activity generates when it processes a '''Batch Folder'''.  It serializes all the extracted '''Data Elements'''' values for the document's '''Data Model'''.
|
 
[[File:2023_Data-Export_02_HowTo_01_07.png]]
[[File:2023_Data-Export_02_HowTo_01_07.png]]
|}
</tab>
</tabs>


=== Configuring a Data Connection ===
=== Configuring a Data Connection ===
Line 277: Line 248:
It is worth noting that this article cannot tell you specifics about permissions in your own environment. The configuration for this article uses Microsoft SQL Server and has given the active Active Directory user full DB Admin privileges to the SQL environment.
It is worth noting that this article cannot tell you specifics about permissions in your own environment. The configuration for this article uses Microsoft SQL Server and has given the active Active Directory user full DB Admin privileges to the SQL environment.


<tabs style="margin:20px">
==== Create a Data Connection ====
<tab name="Create a Data Connection" style="margin:20px">
New '''Data Connections''' are added to the '''Global Resources''' folder of the Node Tree.


=== Create a Data Connection ===
{|cellpadding=10 cellspacing=5
|valign=top style="width:40%"|
New '''Data Connections''' are added to the '''Global Resources''' folder of the Node Tree.


# Right click the '''Global Resources''' folder.
# Right click the '''Global Resources''' folder.
Line 292: Line 258:
#* We've named ours "DB Export"
#* We've named ours "DB Export"
# Press "OK" when finished.
# Press "OK" when finished.
|
 
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_01.png]]
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_01.png]]
|-
 
|valign=top|
 
# This will add the new '''Data Connection''' to the '''Global Resources''' folder.
# This will add the new '''Data Connection''' to the '''Global Resources''' folder.
# Next, we will configure connection settings so that Grooper can interoperate with our SQL server.
# Next, we will configure connection settings so that Grooper can interoperate with our SQL server.
|
 
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_02.png]]
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_02.png]]
|}
</tab>
<tab name="Configure Connection Settings" style="margin:20px">


=== Configure Connection Settings ===
==== Configure Connection Settings ====
 
{|cellpadding=10 cellspacing=5
|valign=top style="width:40%"|
Regardless whether you want to connect to an existing database or create a new one from Grooper, your first step is always the same.  You must first connect to a database server.
Regardless whether you want to connect to an existing database or create a new one from Grooper, your first step is always the same.  You must first connect to a database server.


Grooper can connect to Microsoft SQL servers or any ODBC (Open Database Connectivity) compliant data source.  For the purposes of this tutorial, we will connect to a SQL server.
Grooper can connect to Microsoft SQL servers or any ODBC (Open Database Connectivity) compliant data source.  For the purposes of this tutorial, we will connect to a SQL server.


# However, you can choose to connect to a SQL server or ODBC server using the '''''Connection Settings''''' property.
# However, you can choose to connect to a SQL server or ODBC server using the '''''Connection Settings''''' property.
# Using the dropdown menu, choose either ''SQL Server'' or ''ODBC''
# Using the dropdown menu, choose either ''SQL Server'' or ''ODBC''
#* Again, we will be connecting to a SQL server.  So, ''SQL Server'' is selected.
#* Again, we will be connecting to a SQL server.  So, ''SQL Server'' is selected.
|
 
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_03.png]]
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_03.png]]
|-
 
|valign=top|
 
Next, we need to define settings to access the database server.  All you really need to do this is the server's name and access rights.
Next, we need to define settings to access the database server.  All you really need to do this is the server's name and access rights.


Line 328: Line 289:
#* Otherwise, you'll need to enter a '''''User Name''''' and '''''Password''''' to access the database server here.
#* Otherwise, you'll need to enter a '''''User Name''''' and '''''Password''''' to access the database server here.
# Go ahead and hit "Save" at this point.
# Go ahead and hit "Save" at this point.
|
 
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_04.png]]
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_04.png]]
|-
 
|valign=top|
 
That's it!  You're officially connected to the database server now.  We can now connect to existing databases, import references to their tables (Keep this in the back of your mind.  This will be important later.), create new databases, and new database tables.
That's it!  You're officially connected to the database server now.  We can now connect to existing databases, import references to their tables (Keep this in the back of your mind.  This will be important later.), create new databases, and new database tables.


# If you want to verify your connection, press the "Test Connection" button.
==== Create a New Database from the Data Connection ====
# The following message will appear if you are successfully connected to the SQL server.
|
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_05.png]]
|}
</tab>
<tab name="Create a New Database from the Data Connection" style="margin:20px">
 
At this point, you have two options:
At this point, you have two options:
# Connect to an existing database
# Connect to an existing database
# Create a new database
# Create a new database


{|cellpadding=10 cellspacing=5
|valign=top style="width:40%"|
If you wanted to connect to an existing database, it's very easy.
If you wanted to connect to an existing database, it's very easy.


# Select the '''''Database Name''''' property.
# Select the '''''Database Name''''' property.
# Either type in the database's name or select it from the drop down menu.
# Either type in the database's name or select it from the drop down menu.
#* FYI: Grooper has to ping the database in order to populate the dropdown list.  Depending on the size of your SQL server, it's often quickest to just type in the database name.
#* FYI: Grooper has to ping the database in order to populate the dropdown list.  Depending on the size of your SQL server, it's often quickest to just type in the database name.
|
 
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_06.png]]
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_05.png]]
|}
 


However, now that we're connected to the database, you can also create a brand new database!
However, now that we're connected to the database, you can also create a brand new database!


=== Create a New Database from the Data Connection ===
===== Create a New Database from the Data Connection =====
 
{|cellpadding=10 cellspacing=5
|valign=top style="width:40%"|
# To create a new database, press the "Create Database..." button.
# To create a new database, press the "Create Database..." button.
# This will bring up the "Create Database" window.
# This will bring up the "Create Database" window.
Line 368: Line 318:
#* We named ours "Export_Example_DB"
#* We named ours "Export_Example_DB"
# Press the "Execute" button to create the database.
# Press the "Execute" button to create the database.
|
 
[[File:Data-export-how-to-12.png]]
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_06.png]]
|-
 
|valign=top|
 
# You will see the newly created database's name populate the '''''Database Name''''' property.
# You will see the newly created database's name populate the '''''Database Name''''' property.
# However, as a newly formed, infant database, it has no database tables.  You can see, the "Database Tables" panel is empty.  Next, we will add some database tables using the data structures of the '''Data Models''' in our example '''Content Model'''.
# However, as a newly formed, infant database, it has no database tables.  You can see, the "Database Tables" panel is empty.  Next, we will add some database tables using the data structures of the '''Data Models''' in our example '''Content Model'''.
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_07.png]]
{|class="fyi-box"
|
'''FYI'''
|
|
[[File:Data-export-how-to-13.png]]
If you connect to the server in Microsoft SQL Management Studio, you can verify the database is created.
|-
|valign=top|
{|cellpadding="10" cellspacing="5"
|-style="background-color:#36b0a7; color:white"
|style="font-size:14pt"|'''FYI'''||If you connect to the server in Microsoft SQL Management Studio, you can verify the database is created.


See here, the "Export_Example_DB" is added to the list of databases.  Through the '''Data Connection''' Grooper has a direct connection to this SQL environment to add and alter databases.
See here, the "Export_Example_DB" is added to the list of databases.  Through the '''Data Connection''' Grooper has a direct connection to this SQL environment to add and alter databases.
|}
|}
|
[[File:Data-export-how-to-14.png]]
|}
</tab>
<tab name="Create Database Tables from the Data Connection" style="margin:20px">


=== Create Database Tables from the Data Connection ===
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_08.png]]
 
==== Create Database Tables from the Data Connection ====


We will end up creating three database tables by the end of this section:
We will end up creating three database tables by the end of this section:
Line 397: Line 346:
# A table for the "Personnel Info Report" '''Document Type's''' extracted "PII" '''Data Table'''.
# A table for the "Personnel Info Report" '''Document Type's''' extracted "PII" '''Data Table'''.


=== Table 1:  Employee Report Data ===
===== Table 1:  Employee Report Data =====
 
{|cellpadding=10 cellspacing=5
|valign=top style="width:40%"|
# To create a new database table, press the "Create Table..." button.
# To create a new database table, press the "Create Table..." button.
# This will bring up the "Create Table" window.
# This will bring up the "Create Table" window.
# Database tables are created from Grooper using '''Data Elements''' from a '''Data Model'''.  The '''Data Model's''' '''Data Fields''' and/or '''Data Columns''' will form the columns of the SQL table, housing extracted values from each document folder upon export.  First, you must define the '''Content Type''' (e.g. a '''Content Model''' or one of its '''Document Types''') whose '''Data Model''' you want to use to create the database table.
# Database tables are created from Grooper using '''Data Elements''' from a '''Data Model'''.  The '''Data Model's''' '''Data Fields''' and/or '''Data Columns''' will form the columns of the SQL table, housing extracted values from each document folder upon export.  First, you must define the '''Content Type''' (e.g. a '''Content Model''' or one of its '''Document Types''') whose '''Data Model''' you want to use to create the database table.
# The '''''Content Type''''' property's dropdown menu will present you a mini Node Tree view to select a '''Content Type''' from your '''Content Models''' folder.
# The '''''Data Element''''' property's dropdown menu will present you a mini Node Tree view to select a '''Data Container''' from your '''Data Model'''.
#* In our case, we will select the "Employee Report" '''Document Type''' from our "Example Model - Data Export" '''Content Model'''.
#* In our case, we will select the "Earnings" '''Data Table''' from our "Data Export - Content Model"'s '''Data Model'''.
#* Why didn't we choose the parent '''Content Model'''?  It's all about '''Data Model''' hierarchy and scope.  We want access to all the '''Data Elements''' in the "Employee Report" '''Document Type's''' '''Data Model'''.  If we chose the parent '''Content Model''', we would only have access to its '''Data Model's''' '''Data Elements''', which would not include any of the '''Data Elements''' we want to export.
#* Why didn't we choose the parent '''Data Model'''?  It's all about '''Data Model''' hierarchy and scope.  We want access to all the '''Data Elements''' in the "Earnings" '''Data Table'''.  If we chose the parent '''Data Model''', we would only have access to its immediate '''Data Elements''', which would not include any of the '''Data Elements''' we want to export.
#** '''Data Elements''' are passed from parent '''Data Model''' to child '''Data Model''' ''not'' the other way around.
 
|
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_09.png]]
[[File:Data-export-how-to-15.png]]
 
|-
 
|valign=top|
For the way we will want our table structured, we will need to consider the '''''Create Mode''''' property. In the case of the "Earnings" table, ''Simple'' would create a table based only on the this one table's structure. ''Recursive'' is for more complex tables that have interconnected referencing, which this does not have. However, ''Flatten'' will be our best option. This will take the information from the '''Data Columns''' from this table, and ''flatten'' it with '''Data Fields''' that are siblings to the parent '''Data Table'''. In this case, there are three '''Data Fields''' in the "Header Info" '''Data Section''', which is a sibling to the "Earnings" '''Data Table'''. These three fields will be ''flattened'' into a single row of information with the other '''Data Columns''' from the "Earnings" '''Data Table'''.  
# Next, you will need to select the data scope in the '''Content Type's''' '''Data Model''', using the '''''Data Element Scope''''' property.
# Click the drop-down for the '''''Create Mode''''' property.
#* This property will present you a drop down to select either the parent '''Data Model''' or sub-levels in its '''Data Element''' scope, branched by '''Data Section''' or '''Data Table''' elements.
# Select the ''Flatten'' option.
#* Choosing a data scope is all about defining which '''Data Elements''' are accessible for database table creation (and ultimately data export to the created table).
 
# In our case, we want to choose the "Earnings" '''Data Table''' for our scope.
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_10.png]]
#* Think back to the notion of the one-to-many relationship. This database table can have a dynamic number of rows and the '''Data Columns''' are capable of capturing and reporting back unlimited instances of data, hence multiple rows. The '''Data Fields''' within this scope, however, are only capable of capturing and returning a single piece of data.
 
#* But, given the nature of hierarchy inheritance, at the "Earnings" '''Data Table''' scope, the database table that will be created will make columns not just for the '''Data Columns''' of the '''Data Table''', but for each of the '''Data Fields''' contained within the '''Data Model's''' scope as well (i.e. The "Last Name", "First Name" and "Employee ID" '''Data Fields''').
 
#* FYI: Were there '''Data Fields''' further up the inheritance tree, say at the base '''Data Model''' of the parent '''Content Model''', the database table would also inherit those as well.
#* In other words, think about what '''Data Elements''' you want access to and go down the '''Data Model's''' hierarchy to widen the '''Data Element''' scope.
|
[[File:Data-export-how-to-16.png]]
|-
|valign=top|
# The '''''Table Name''''' property will auto-populate a concatenation of the '''''Content Type''''' and '''''Data Element Scope''''' properties string values.
#* However, you can change this to whatever you want.
# Now, you're ready to create the database table.  Press the "Execute" button.
|
[[File:Data-export-how-to-17.png]]
|-
|valign=top|
# Here's where '''Grooper''' is doing the hard work for us. Notice in the "Review/Edit SQL Statement" window the SQL Statement required to create our table is already written for us.
# Here's where '''Grooper''' is doing the hard work for us. Notice in the "Review/Edit SQL Statement" window the SQL Statement required to create our table is already written for us.
# However, you can edit this statement, if need be.
# However, you can edit this statement, if need be.
#* For example, at the time of writing this article there was a bug involving the "Employee ID" '''Data Field'''.  It's '''''Value Type''''' in Grooper is set to ''Int16''.  This was not properly converting to a "smallint" SQL data type for the corresponding SQL column.  So we added <code>smallint</code> to the SQL Statement after <code>[Employee ID]</code>.
#* For example, at the time of writing this article there was a bug involving the "Employee ID" '''Data Field'''.  It's '''''Value Type''''' in Grooper is set to ''Int16''.  This was not properly converting to a "smallint" SQL data type for the corresponding SQL column.  So we added <code>smallint</code> to the SQL Statement after <code>[Employee ID]</code>.
# Click the "Run SQL Statement" button to create the table.
# Click the "Run SQL Statement" button to create the table.
|
 
[[File:Data-export-how-to-18.png]]
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_11.png]]
|-
 
|valign=top|
 
# Upon successfully creating the table, the "Database Tables" panel will have our newly created table listed.</li>
# Upon successfully creating the table, the "Database Tables" panel will have our newly created table listed.</li>
#* It will initially display with a red dot on the icon. This will change to a green dot when we import this table's reference (more on that later).
#* It will initially display with a red dot on the icon. This will change to a green dot when we import this table's reference (more on that later).
Line 444: Line 377:
# The "Data Preview" panel will display data within the table.
# The "Data Preview" panel will display data within the table.
#* Because this table was just created, it will not have any data to display.  We haven't exported any data to it yet!
#* Because this table was just created, it will not have any data to display.  We haven't exported any data to it yet!
|
[[File:Data-export-how-to-19.png]]
|}


=== Table 2: Personnel Info Report non-PII Data ===
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_12.png]]


===== Table 2: Personnel Info Report non-PII Data =====
For the other two tables, it's mostly a repeat of the same steps, just taking care to select the appropriate '''Content Type''' and '''Data Element''' scope.
For the other two tables, it's mostly a repeat of the same steps, just taking care to select the appropriate '''Content Type''' and '''Data Element''' scope.


{|cellpadding=10 cellspacing=5
 
|valign=top style="width:40%"|
# To create the second database table, right-click the '''Data Connection''' and choose "Create Table".
# To create the second database table, press the "Create Table..." button.
# Click the drop-down for the '''''Data Element''''' property ...
# Select the appropriate '''Content Type''', using the '''''Content Type''''' property.
# ... and choose the "non-PII" '''Data Table'''.
#* For this database table, we need access to the "Personnel Info Report" '''Document Type's''' '''Data Model'''.  We have, hence, selected the "Personnel Info Report" '''Document Type''' of our example '''Content Model'''.
# Click the "Execute" button.
# Select the appropriate data scope, using the '''''Data Element Scope''''' property.
#* We don't need to worry about the '''''Create Mode''''' property in this case as we only need the contents of the selected '''Data Table'''. ''Simple'' would be a perfectly fine setting, and is technically more accurate here, but leaving it at ''Flatten'' won't technically do anything.
# This table is going to house all the non-PII related data. So, we have selected the "non-PII" '''Data Table''' element.
 
#* This will create a database table using ''only its'' '''Data Columns'''.  The "PII" '''Data Table's''' columns will be ''out of scope''.
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_13.png]]
|
 
[[File:Data-export-how-to-20.png]]
 
|-
|valign=top|
# Press "Execute".
# Then, press "Run SQL Statement".
|
[[File:Data-export-how-to-21.png]]
|-
|valign=top|
# Success!  The table is now successfully created.
# Success!  The table is now successfully created.
|
[[File:Data-export-how-to-22.png]]
|}


=== Table 3: Personnel Info Report PII Data ===
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_14.png]]


{|cellpadding=10 cellspacing=5
===== Table 3: Personnel Info Report PII Data =====
|valign=top style="width:40%"|
This database table can be created with the exact same steps as described above with just one key difference:
This database table can be created with the exact same steps as described above with just one key difference:


# The '''''Data Element Scope''''' will be set to the "PII" '''Data Table''' ''not'' the "non-PII" '''Data Table'''.
|
[[File:Data-export-how-to-23.png]]
|-
|valign=top|
:2.&nbsp; We now have our third database table added to the SQL database.
::* We just have one last thing to do before we export data to these newly created database tables:  import their references.
|
[[File:Data-export-how-to-24.png]]
|}
</tab>
<tab name="Import Table References" style="margin:20px">


=== Import Table References ===
# The '''''Data Element''''' property will be set to the "PII" '''Data Table''' ''not'' the "non-PII" '''Data Table'''.
 
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_15.png]]


Before we can export data to these newly created tables, we must import their table references.  This part is ''critical'' in order for Grooper to interact with a database table, whether to export data using '''''Data Export''''' or perform a '''''Database Lookup''''' operation.  Importing the table references will give Grooper an object it can reference when mapping data between Grooper and the database table, ultimately allowing for data to flow from extracted '''Batch Folders''' to the database table.


{|cellpadding=10 cellspacing=5
We now have our third database table added to the SQL database.
|valign=top style="width:40%"|
Importing a table reference is as simple as a click of a button.


# Select the database table you wish to import from the '''Data Connection's''' "Database Tables" panel.
[[File:2023_Data-Export_02_HowTo_02_Configuring-a-Data-Connection_16.png]]
#* We're starting with the "Employee_Report_Earnings" table.
# Press the "Import Table Reference" button.
# You will see the following message upon successful import.
|
[[File:Data-export-how-to-25.png]]
|-
|valign=top|
# This will create a '''Database Table''' object, as a child of the '''Data Connection'''.
#* We will utilize this object later when we get to configuring our export.
# Also, when the database table is imported the red circle on its icon will change to green.
|
[[File:Data-export-how-to-26.png]]
|-
|valign=top|
# We will also need to import the remaining two table references.
# Next, we will use these three table references to export document data over our '''Data Connection''' to these SQL database tables.
|
[[File:Data-export-how-to-27.png]]
|}
</tab>
<span style="font-size:125%; margin:20px">'''[[#Configuring a Data Connection|Back to top to continue to next tab]]'''</span>
</tabs>


=== Configuring Export Behaviors for Data Export ===
=== Configuring Export Behaviors for Data Export ===
'''''Data Export''''' is one of the '''''Export Type''''' options when configuring an '''''Export Behavior'''''.  '''''Export Behaviors''''' control what document content for a '''Batch Folder''' is exported where, according to its classified '''Document Type'''.  As such, in order to configure a '''''Data Export''''', you must first configure an '''''Export Behavior''''' for a '''Content Type''' (a '''Content Model''' or its child '''Content Categories''' or '''Document Types''').
'''''Data Export''''' is one of the '''''Export Type''''' options when configuring an '''''Export Behavior'''''.  '''''Export Behaviors''''' control what document content for a '''Batch Folder''' is exported where, according to its classified '''Document Type'''.  As such, in order to configure a '''''Data Export''''', you must first configure an '''''Export Behavior''''' for a '''Content Type''' (a '''Content Model''' or its child '''Content Categories''' or '''Document Types''').


Line 545: Line 428:
When the '''Export''' activity processes each '''Batch Folder''' it will execute the '''''Export Behaviors''''', according to their configuration settings.
When the '''Export''' activity processes each '''Batch Folder''' it will execute the '''''Export Behaviors''''', according to their configuration settings.


{|cellpadding="10" cellspacing="5"
{|class="fyi-box"
|-style="background-color:#36b0a7; color:white"
|
|style="font-size:14pt"|'''FYI'''||In general, users will choose to configure '''''Export Behaviors''''' either on the '''Content Type''' object it applies to ''or'' local to the '''Export''' activity step in a '''Batch Process'''.   
'''FYI'''
|
In general, users will choose to configure '''''Export Behaviors''''' either on the '''Content Type''' object it applies to ''or'' local to the '''Export''' activity step in a '''Batch Process'''.   


This may just boil down to personal preference.  There is no functional difference between an '''''Export Behavior''''' configured on a '''Content Type''' or an '''''Export Behavior''''' configured on an '''Export Step''', upon completing their configuration.  In either case, they will accomplish the same goal.
This may just boil down to personal preference.  There is no functional difference between an '''''Export Behavior''''' configured on a '''Content Type''' or an '''''Export Behavior''''' configured on an '''Export Step''', upon completing their configuration.  In either case, they will accomplish the same goal.
Line 554: Line 439:
|}
|}


<tabs>
==== Add an Export Behavior ====
<tab name="Add an Export Behavior" style="margin:20px">
===== Option 1: Content Type Export Behaviors =====
=== Add an Export Behavior ===
 
=== Option 1: Content Type Export Behaviors ===


{|cellpadding=10 cellspacing=5
{|cellpadding=10 cellspacing=5
Line 569: Line 451:
# Then,m press the ellipsis button at the end of the property.
# Then,m press the ellipsis button at the end of the property.
|
|
[[File:Data-export-how-to-export-behaviors-01.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_01.png]]
|-
|-
|valign=top|
|valign=top|
Line 579: Line 461:
#** For example, our two '''Document Types''' need different '''''Export Behavior''''' configurations.  We would ''''not''''' want to configure their parent '''Content Model's''' '''''Export Behavior'''''.  That would apply that single export configuration to ''all'' '''Document Types'''.  That's not going to work for us.  The "Employee Report" documents' data need to go to one location and the "Personnel Info Report" documents' data need to go somewhere entirely different.  Instead, we will end up configuring the '''''Behaviors''''' property of both '''Document Types''' individually.  Thus, we end up with two '''''Export Behavior''''' configurations for the '''Content Model'''.
#** For example, our two '''Document Types''' need different '''''Export Behavior''''' configurations.  We would ''''not''''' want to configure their parent '''Content Model's''' '''''Export Behavior'''''.  That would apply that single export configuration to ''all'' '''Document Types'''.  That's not going to work for us.  The "Employee Report" documents' data need to go to one location and the "Personnel Info Report" documents' data need to go somewhere entirely different.  Instead, we will end up configuring the '''''Behaviors''''' property of both '''Document Types''' individually.  Thus, we end up with two '''''Export Behavior''''' configurations for the '''Content Model'''.
|
|
[[File:Data-export-how-to-export-behaviors-02.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_02.png]]
|-
|-
|valign=top|
|valign=top|
Line 586: Line 468:
#* Next, we will add a '''''Data Export''''' definition.
#* Next, we will add a '''''Data Export''''' definition.
|
|
[[File:Data-export-how-to-export-behaviors-03.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_03.png]]
|}
|}


=== Option 2: Export Activity Export Behaviors ===
===== Option 2: Export Activity Export Behaviors =====
 
{|cellpadding=10 cellspacing=5
|valign=top style="width:40%|
'''''Export Behaviors''''' can also be configured as part of the '''Export''' activity's configuration.  These are called "local" '''''Export Behaviors'''''.  They are local to the '''Export''' activity step in the '''Batch Process'''.
'''''Export Behaviors''''' can also be configured as part of the '''Export''' activity's configuration.  These are called "local" '''''Export Behaviors'''''.  They are local to the '''Export''' activity step in the '''Batch Process'''.


Line 602: Line 481:
# To add an '''''Export Behavior''''', select the '''''Export Behaviors''''' property.
# To add an '''''Export Behavior''''', select the '''''Export Behaviors''''' property.
# Then, press the ellipsis button at the end of the property.
# Then, press the ellipsis button at the end of the property.
|
 
[[File:Data-export-how-to-export-behaviors-04.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_04.png]]
|-
 
|valign=top|
 
# This will bring up the '''''Export Behaviors''''' collection editor window.
# This will bring up the '''''Export Behaviors''''' collection editor window.
# Press the "Add" button to add a new '''''Export Behavior'''''
# Press the "Add" button to add a new '''''Export Behavior'''''
Line 616: Line 495:
#* Again, children '''Content Type''' objects will inherit export settings from their parent '''Content Type's''' '''''Export Behavior''''' configuration.  However, multiple '''''Export Behaviors''''' may be added locally to the '''Export''' activity.
#* Again, children '''Content Type''' objects will inherit export settings from their parent '''Content Type's''' '''''Export Behavior''''' configuration.  However, multiple '''''Export Behaviors''''' may be added locally to the '''Export''' activity.
#** For example, since both our '''Document Type''' needed a unique '''''Export Behavior''''' configuration, we would add one '''''Export Behavior''''' to the list for each one.
#** For example, since both our '''Document Type''' needed a unique '''''Export Behavior''''' configuration, we would add one '''''Export Behavior''''' to the list for each one.
|valign=top|
 
[[File:Data-export-how-to-export-behaviors-05.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_05.png]]
|-
 
|valign=top|
 
# Here, we have selected the "Employee Report" '''Document Type'''.  This '''''Export Behavior''''' would then only apply to '''Batch Folders''' of this '''Document Type'''.
# Here, we have selected the "Employee Report" '''Document Type'''.  This '''''Export Behavior''''' would then only apply to '''Batch Folders''' of this '''Document Type'''.
# Once a '''Content Type''' is selected, you can add one more more '''''Export Definitions''''' with the '''''Export Definitions''''' property.
# Once a '''Content Type''' is selected, you can add one more more '''''Export Definitions''''' with the '''''Export Definitions''''' property.
#* We will discuss adding a '''''Data Export''''' definition next.
#* We will discuss adding a '''''Data Export''''' definition next.
|
# Click the "+" button.
[[File:Data-export-how-to-export-behaviors-06.png]]
 
|}
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_06.png]]
</tab>
<tab name="Add an Export Definition" style="margin:20px">
=== Add an Export Definition ===


{|cellpadding=10 cellspacing=5
==== Add an Export Definition ====
|valign=top style="width:40%"|
# We will choose to configure the '''''Export Behavior''''' using "Option 1", adding it to the "Employee Report" '''Document Type'''
# We will choose to configure the '''''Export Behavior''''' using "Option 1", adding it to the "Employee Report" '''Document Type'''
# We will add the ''''Export Behavior''''' to its set of '''''Behaviors''''' properties.
# We will add the ''''Export Behavior''''' to its set of '''''Behaviors''''' properties.
|
 
[[File:Data-export-how-to-export-behaviors-07.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_07.png]]
|-
 
|valign=top|
 
Regardless if you choose to configure the '''''Export Behavior''''' on a '''Content Type''' object, or if you configure it local to to '''Export''' activity's configuration, your next step is adding an '''''Export Definition'''''.
Regardless if you choose to configure the '''''Export Behavior''''' on a '''Content Type''' object, or if you configure it local to to '''Export''' activity's configuration, your next step is adding an '''''Export Definition'''''.


# Once you've added an '''''Export Behavior''''', select the '''''Export Definitions''''' property.
# Once you've added an '''''Export Behavior''''', select the '''''Export Definitions''''' property.
# To add an '''''Export Definition''''', press the ellipsis button at the end of the property.
# To add an '''''Export Definition''''', press the ellipsis button at the end of the property.
|
 
[[File:Data-export-how-to-export-behaviors-08.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_08.png]]
|-
 
|valign=top|
 
# This will bring up an '''''Export Definition''''' list editor to add one or more '''''Export Types'''''.
# This will bring up an '''''Export Definition''''' list editor to add one or more '''''Export Types'''''.
#* Next, we will add a '''''Data Export''''' definition to the list.
#* Next, we will add a '''''Data Export''''' definition to the list.
|
 
[[File:Data-export-how-to-export-behaviors-09.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_09.png]]
|}
 
</tab>
==== Add a Data Export ====
<tab name="Add a Data Export" style="margin:20px">
=== Add a Data Export ===


'''''Export Definitions''''' functionally determine three things:
'''''Export Definitions''''' functionally determine three things:
Line 661: Line 534:
# '''Format''' - What format the exported content takes, such as a PDF file or XML data file.
# '''Format''' - What format the exported content takes, such as a PDF file or XML data file.


{|cellpadding=10 cellspacing=5
 
|valign=top style="width:40%"|
'''''Export Definitions''''' do this by adding one or more '''''Export Type''''' configurations to the definition list.  The '''''Export Type''''' you choose determines how you want to export content to which platform.  In our case, we want to use a '''Data Connection''' to export extracted document data ("Content") to a database table ("Location" and "Format").  We will add a '''''Data Export''''' to the definition list.
'''''Export Definitions''''' do this by adding one or more '''''Export Type''''' configurations to the definition list.  The '''''Export Type''''' you choose determines how you want to export content to which platform.  In our case, we want to use a '''Data Connection''' to export extracted document data ("Content") to a database table ("Location" and "Format").  We will add a '''''Data Export''''' to the definition list.


# To do this, press the "Add" button.
# To do this, press the "Add" button.
# Choose ''Data Export'' from the list.
# Choose ''Data Export'' from the list.
|
 
[[File:Data-export-how-to-export-behaviors-10.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_10.png]]
|-
 
|valign=top|
 
# This will add an unconfigured '''''Data Export''''' to the '''''Export Definitions''''' list.
# This will add an unconfigured '''''Data Export''''' to the '''''Export Definitions''''' list.
# For all '''''Data Export''''' configurations, the first step is configuring the '''''Connection''''' property.
# For all '''''Data Export''''' configurations, the first step is configuring the '''''Connection''''' property.
# Use the dropdown menu to select a '''Data Connection''' from the node tree.
# Use the dropdown menu to select a '''Data Connection''' from the node tree.
#* This will provide Grooper with the information required to connect to the external database upon export.
#* This will provide Grooper with the information required to connect to the external database upon export.
|
 
[[File:Data-export-how-to-export-behaviors-11.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_11.png]]
|-
 
|valign=top|
 
# With the '''Data Connection''' established, the next step is to map data from Grooper to a table in the database.
# With the '''Data Connection''' established, the next step is to map data from Grooper to a table in the database.
# Next, we will review using the '''''Table Mappings''''' property to map '''Data Elements''' in a '''Data Model''' to corresponding column locations in a database table.
# Next, we will review using the '''''Table Mappings''''' property to map '''Data Elements''' in a '''Data Model''' to corresponding column locations in a database table.
|
[[File:Data-export-how-to-export-behaviors-12.png]]
|}
</tab>
<tab name="Table Mappings Example 1: Flattening a Data Model" style="margin:20px">


=== Table Mappings Example 1: Flattening a Data Model ===
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_12.png]]
{|cellpadding=10 cellspacing=5
 
|valign=top style="width:50%"|
==== Table Mappings Example 1: Flattening a Data Model ====
We will continue configuring our "Employee Report" '''Document Type's''' '''''Data Export''''' first.  For this document, we have to deal with a "one-to-many" relationship between data that exists once on the document, and the dynamic data in the multiple rows in the "Earnings" table.
We will continue configuring our "Employee Report" '''Document Type's''' '''''Data Export''''' first.  For this document, we have to deal with a "one-to-many" relationship between data that exists once on the document, and the dynamic data in the multiple rows in the "Earnings" table.


Line 695: Line 562:


We will essentially re-output the single instance values, marrying them to every row instance output for the table on the document.  Think of the single instance values as "document level".  These single values ("Last Name", "First Name", "Employee ID") pertain to the whole document.  Therefore, they also pertain to every row of information in the "Earnings" table.
We will essentially re-output the single instance values, marrying them to every row instance output for the table on the document.  Think of the single instance values as "document level".  These single values ("Last Name", "First Name", "Employee ID") pertain to the whole document.  Therefore, they also pertain to every row of information in the "Earnings" table.
|
 
[[File:Data-export-how-to-export-behaviors-13.png]]
[[File:Data-export-how-to-export-behaviors-13.png]]
|}


{|cellpadding=10 cellspacing=5
 
|valign=top style="width:40%"|
We accomplish this feat through '''''Table Mappings'''''.  This will allow us to hook up the right '''Data Elements''' in a '''Data Model''' to the right database table columns upon exporting collected values.  Much like data hierarchy scope was important when we created this database, so will it be when we configure '''''Table Mappings''''' for export.
We accomplish this feat through '''''Table Mappings'''''.  This will allow us to hook up the right '''Data Elements''' in a '''Data Model''' to the right database table columns upon exporting collected values.  Much like data hierarchy scope was important when we created this database, so will it be when we configure '''''Table Mappings''''' for export.


# With the '''''Data Export''''' selected, select the '''''Table Mappings''''' property.
# With the '''''Data Export''''' selected, select the '''''Table Mappings''''' property.
# Press the ellipsis button at the end.
# Press the ellipsis button at the end.
|
 
[[File:Data-export-how-to-export-behaviors-14.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_13.png]]
|-
 
|valign=top|
 
# This will bring up the "Table Mappings" collection editor.
# This will bring up the "Table Mappings" collection editor.
# Press the "Add" button to add a new set of mappings.
# Press the "Add" button to add a new set of mappings.
Line 714: Line 580:
# In our case, we're choosing the "Earnings" '''Data Table'''.
# In our case, we're choosing the "Earnings" '''Data Table'''.
#* Selecting this '''Data Table''' as the scope will not only allow mapping to its '''Data Columns''', but all '''Data Fields''' up its logical hierarchical tree path (i.e. "Last Name", "First Name", and "Employee ID").
#* Selecting this '''Data Table''' as the scope will not only allow mapping to its '''Data Columns''', but all '''Data Fields''' up its logical hierarchical tree path (i.e. "Last Name", "First Name", and "Employee ID").
|
 
[[File:Data-export-how-to-export-behaviors-16.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_14.png]]
|-
 
|valign=top|
 
Next we need to define which database table we're mapping to.  There are now three databases in the database connected to our '''Data Connection'''.  Each of their table references have been imported to Grooper.  We need to pick which one we want to use.
Next we need to define which database table we're mapping to.  There are now three databases in the database connected to our '''Data Connection'''.  Each of their table references have been imported to Grooper.  We need to pick which one we want to use.


# Choose which database table you want to map using the the '''''Target Table''''' property.
# Choose which database table you want to map using the the '''''Target Table''''' property.
Line 724: Line 591:
#* In our case the "Employee_Report_Earnings" database table.
#* In our case the "Employee_Report_Earnings" database table.
#* FYI:  Without importing the database table's reference, creating the child '''Database Table''' object for our '''Data Connection''', you would not see the database table listed here.
#* FYI:  Without importing the database table's reference, creating the child '''Database Table''' object for our '''Data Connection''', you would not see the database table listed here.
|
 
[[File:Data-export-how-to-export-behaviors-17.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_15.png]]
|-
 
|valign=top|
 
Now that we have a source data scope selected (where we're mapping from) and a target database table selected (where we're mapping to), we will map the '''Data Elements''' in our '''Data Model's''' scope to columns in the targeted database table.
Now that we have a source data scope selected (where we're mapping from) and a target database table selected (where we're mapping to), we will map the '''Data Elements''' in our '''Data Model's''' scope to columns in the targeted database table.


# Select the '''''Column Mappings''''' property.
# Select the '''''Column Mappings''''' property.
# Press the ellipsis button at the end.
# Press the ellipsis button at the end.
|
 
[[File:Data-export-how-to-export-behaviors-18.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_16.png]]
|-
 
|valign=top|
 
# This will bring up the "Column Map" editor.
# This will bring up the "Column Map" editor.
# Each database table column will be listed as a property in the grid.
# Each database table column will be listed as a property in the grid.
Line 742: Line 610:
#** For '''Data Elements''' inherited from a parent scope, they will be listed as ''"Scope Source"."Data Element"''.  For example, the "Last Name" '''Data Field''' was inherited from the "Employee Report" '''Document Type's''' base '''Data Model'''.  So, it is listed as "Employee_Report.Last_Name".
#** For '''Data Elements''' inherited from a parent scope, they will be listed as ''"Scope Source"."Data Element"''.  For example, the "Last Name" '''Data Field''' was inherited from the "Employee Report" '''Document Type's''' base '''Data Model'''.  So, it is listed as "Employee_Report.Last_Name".
#* For the '''''Last Name''''' database column, we have selected the ''Employee_Report.Last_Name'' '''Data Element'''.
#* For the '''''Last Name''''' database column, we have selected the ''Employee_Report.Last_Name'' '''Data Element'''.
|
 
[[File:Data-export-how-to-export-behaviors-19.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_17.png]]
|-
 
|valign=top|
 
There is also a mapping shortcut to automatically assing mappings if a '''Data Element's''' name matches a database column's name.
There is also a mapping shortcut to automatically assing mappings if a '''Data Element's''' name matches a database column's name.


# Right-click any property in the grid.
# Right-click any property in the grid.
# Select "Auto-Map..."
# Select "Auto-Map..."
|
 
[[File:Data-export-how-to-export-behaviors-20.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_18.png]]
|-
 
|valign=top|
 
# Database table columns will be automatically mapped to '''Data Elements''' as long as their names match.
# Database table columns will be automatically mapped to '''Data Elements''' as long as their names match.
#* Furthermore, since we created this database table from Grooper, using the same '''Data Model''', ''all'' of these column names and '''Data Element''' names will match.
#* Furthermore, since we created this database table from Grooper, using the same '''Data Model''', ''all'' of these column names and '''Data Element''' names will match.
# Press "OK" to finish configuring mappings.
# Press "OK" to finish configuring mappings.
|
 
[[File:Data-export-how-to-export-behaviors-21.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_19.png]]
|-
 
|valign=top|
 
We now have everything we need to export data from "Employee Report" documents to a database, using '''''Data Export'''''.
We now have everything we need to export data from "Employee Report" documents to a database, using '''''Data Export'''''.


# Press "OK" on this and all subsequent windows to finalize the '''''Export Behavior''''' configuration.
# Press "OK" on this and all subsequent windows to finalize the '''''Export Behavior''''' configuration.
Line 769: Line 638:


Before testing the '''Export''' step, in the next tab, we will configure another '''''Data Export''''' for the "Personnel Info Report" '''Document Type''' with its own set of database table mappings to export their extracted data to two different database tables.
Before testing the '''Export''' step, in the next tab, we will configure another '''''Data Export''''' for the "Personnel Info Report" '''Document Type''' with its own set of database table mappings to export their extracted data to two different database tables.
|
[[File:Data-export-how-to-export-behaviors-22.png]]
|}


</tab>
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_20.png]]
<tab name="Table Mappings Example 2: Exporting to Multiple Database Tables" style="margin:20px">


=== Table Mappings Example 2: Exporting to Multiple Database Tables ===
=== Table Mappings Example 2: Exporting to Multiple Database Tables ===
Line 782: Line 647:
In this example, we will take the extracted data from our "Personnel Info Report" '''Document Type''' and export PII information to one database table and non-PII information to a different table, using two '''''Data Export''''' definitions.
In this example, we will take the extracted data from our "Personnel Info Report" '''Document Type''' and export PII information to one database table and non-PII information to a different table, using two '''''Data Export''''' definitions.


{|cellpadding=10 cellspacing=5
 
|valign=top style="width:40%"|
# We want to export data for the "Personnel Info Report" documents.  We will configure the '''''Export Behavior'''''' using the "Personnel Info Report" '''Document Type'''.
# We want to export data for the "Personnel Info Report" documents.  We will configure the '''''Export Behavior'''''' using the "Personnel Info Report" '''Document Type'''.
# We've already added the '''''Export Behavior''''' to the '''''Behaviors''''' collection list.
# We've already added the '''''Export Behavior''''' to the '''''Behaviors''''' collection list.
Line 789: Line 653:
# We've already pointed the '''''Connection''''' property to our "DB Export" '''Connection Type'''.
# We've already pointed the '''''Connection''''' property to our "DB Export" '''Connection Type'''.
# Next, we will assign the '''''Table Mappings'''''.
# Next, we will assign the '''''Table Mappings'''''.
|
 
[[File:Data-export-how-to-export-behaviors-24.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_21.png]]
|-
 
|valign=top|
 
# Using the "Add" button, we've added a '''''Table Mapping''''' for the first of the two '''Data Table''' elements used to collect information from the report..
# Using the "Add" button, we've added a '''''Table Mapping''''' for the first of the two '''Data Table''' elements used to collect information from the report..
# For the '''''Scource Scope''''', we've selected the "non-PII" '''Data Table'''.
# For the '''''Scource Scope''''', we've selected the "non-PII" '''Data Table'''.
# We want to all the data Grooper collects for that '''Data Table''' to the "Personnel_Info_Report_non_PII" database table.  We have selected that database table for the '''''Target Table'''''.
# We want to all the data Grooper collects for that '''Data Table''' to the "Personnel_Info_Report_non_PII" database table.  We have selected that database table for the '''''Target Table'''''.
# All that's left is to assign our '''''Column Mappings'''''.
# All that's left is to assign our '''''Column Mappings'''''.
|
 
[[File:Data-export-how-to-export-behaviors-25.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_22.png]]
|-
 
|valign=top|
 
# Next, we mapped our source '''Data Elements''' (The '''Data Columns''' in the "non-PII" '''Data Table''' in this case) to our target database table columns.
# Next, we mapped our source '''Data Elements''' (The '''Data Columns''' in the "non-PII" '''Data Table''' in this case) to our target database table columns.
#* Since the names all matched, we just used the "Auto Map" feature.
#* Since the names all matched, we just used the "Auto Map" feature.
# Press "OK" to finish.
# Press "OK" to finish.
|
 
[[File:Data-export-how-to-export-behaviors-26.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_23.png]]
|-
 
|valign=top|
 
Now we just need to set up mappings for the "PII" '''Data Table'''.  In this case, we're exporting to the same database, just two different database tables within it.  Since we're already collecting mappings for the database connected to using the "DB Export" '''Data Connection''', all we need to do as add another set of '''''Table Mappings'''''.
Now we just need to set up mappings for the "PII" '''Data Table'''.  In this case, we're exporting to the same database, just two different database tables within it.  Since we're already collecting mappings for the database connected to using the "DB Export" '''Data Connection''', all we need to do as add another set of '''''Table Mappings'''''.


# Press the "Add" button to add a new set of mappings.
# Press the "Add" button to add a new set of mappings.
Line 815: Line 680:
# Last but not least, we've mapped our source '''Data Elements''' to their target database table columns using the '''''Column Mappings''''' property.
# Last but not least, we've mapped our source '''Data Elements''' to their target database table columns using the '''''Column Mappings''''' property.


 
{|class="fyi-box"
{|cellpadding="10" cellspacing="5"
|
|-style="background-color:#36b0a7; color:white"
'''FYI'''
|style="font-size:14pt"|'''FYI'''||Here, we added two sets of table mappings to two database tables in the same database.  What if you wanted to add two sets of mappings to database tables in ''different'' databases?
|
Here, we added two sets of table mappings to two database tables in the same database.  What if you wanted to add two sets of mappings to database tables in ''different'' databases?


That's easily doable.  You would need two '''Data Connections''', one to connect Grooper to each individual database.  Then, you would need to add two '''''Data Export''''' definitions, each one using one of the two '''Data Connections'''.  From there, you'd add the individual table mappings to each individual '''''Data Export'''''.
That's easily doable.  You would need two '''Data Connections''', one to connect Grooper to each individual database.  Then, you would need to add two '''''Data Export''''' definitions, each one using one of the two '''Data Connections'''.  From there, you'd add the individual table mappings to each individual '''''Data Export'''''.
|}
|}
|
 
[[File:Data-export-how-to-export-behaviors-27.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_24.png]]
|-
 
|valign=top|
 
We now have everything we need to export data from "Personnel Info Report" documents to two tables in a database, using '''''Data Export'''''.
We now have everything we need to export data from "Personnel Info Report" documents to two tables in a database, using '''''Data Export'''''.


# Press "OK" on this and all subsequent windows to finalize the '''''Export Behavior''''' configuration.
# Press "OK" on this and all subsequent windows to finalize the '''''Export Behavior''''' configuration.
Line 832: Line 699:


Next, we will apply the '''Export''' activity to the document '''Batch Folders''' in our sample '''Batch''', which will export data according to their '''Document Type's''' '''''Export Behavior''''' using the '''''Data Export''''' definitions.
Next, we will apply the '''Export''' activity to the document '''Batch Folders''' in our sample '''Batch''', which will export data according to their '''Document Type's''' '''''Export Behavior''''' using the '''''Data Export''''' definitions.
|
 
[[File:Data-export-how-to-export-behaviors-28.png]]
[[File:2023_Data-Export_02_HowTo_03_Configuring-Export-Behaviors-for-Data-Export_25.png]]
|}
</tab>
<span style="font-size:125%; margin:20px">'''[[#Configuring a Data Connection|Back to top to continue to next tab]]'''</span>
</tabs>


=== Applying the Export Activity and Reviewing the Results ===
=== Applying the Export Activity and Reviewing the Results ===
==== Process the Export Step ====
With the two '''''Export Behaviors''''' configured, we can now test our export.  '''''Export Behaviors''''' are executed by the '''Export''' activity.


<tabs style="margin:20px">
<tab name="Process the Export Step" style="margin:20px">
=== Process the Export Step ===
{|cellpadding=10 cellspacing=5
|valign=top style="width:40%"|
With the two '''''Export Behaviors''''' configured, we can now test our export.  '''''Export Behaviors''''' are executed by the '''Export''' activity.


# We will use this example '''Batch Process''' to demonstrate our '''''Data Export''''' configurations detailed in the previous tutorial.
# We will use this example '''Batch Process''' to demonstrate our '''''Data Export''''' configurations detailed in the previous tutorial.
Line 854: Line 711:
# FYI:  Because we configured the '''''Export Behavior''''' on '''Content Type''' objects (using the two '''Document Types'''' '''''Behaviors''''' property editor), we ''do not'' have to configure the '''Export''' activity's local properties.
# FYI:  Because we configured the '''''Export Behavior''''' on '''Content Type''' objects (using the two '''Document Types'''' '''''Behaviors''''' property editor), we ''do not'' have to configure the '''Export''' activity's local properties.
#* We've given Grooper all the information it needs to export content.  The '''Export''' activity will go through each '''Batch Folder''' in the '''Batch'''.  It will see the '''Batch Folders''' are classified with one of the '''Document Types''' in our '''Content Model''' and use their '''''Export Behavior''''' configuration settings to export document content.
#* We've given Grooper all the information it needs to export content.  The '''Export''' activity will go through each '''Batch Folder''' in the '''Batch'''.  It will see the '''Batch Folders''' are classified with one of the '''Document Types''' in our '''Content Model''' and use their '''''Export Behavior''''' configuration settings to export document content.
|
 
[[File:Data-export-how-to-export-behaviors-29.png]]
[[File:2023_Data-Export_02_HowTo_04_Applying-the-Export-Activity-and-Reviewing-the-Results_01.png]]
|-
 
|valign=top|
 
We will test our export using the '''Export''' activity's "Unattended Activity Tester" tab.
We will test our export using the '''Export''' activity's "Unattended Activity Tester" tab.


# Expand the '''Batch Process''' to reveal its child '''Batch Step''' nodes.
# Expand the '''Batch Process''' to reveal its child '''Batch Step''' nodes.
# Select the '''Export''' activity step.
# Select the '''Export''' activity step.
# Switch to the "Unattended Activity Tester" tab.
# Switch to the "Activity Tester" tab.
# Press the "Process All..." button.
# Select the documents at the appropriate scope, and press the "Test the Activity" button.
#* On the subsequent screen press the "Start" button to start processing the '''Batch'''.  This will apply the '''Export''' activity, as configured in the '''Batch Process''' to all items in the activity's scope (Folder Level 1 in our case)
#* You could also select the "Data Export - Batch" root "Batch Folder" and use the "Submit a job" button to process these documents through a job, which will allow it to funtion with multiple threads.
|
[[File:Data-export-how-to-export-behaviors-30.png]]
|}
</tab>
<tab name="Review the Export" style="margin:20px">


=== Review the Export ===
[[File:2023_Data-Export_02_HowTo_04_Applying-the-Export-Activity-and-Reviewing-the-Results_02.png]]


==== Review the Export ====
You can easily review our exported data in one of two ways:
You can easily review our exported data in one of two ways:
* In the "Data Preview" panel of any of the '''Database Table''' reference objects.
* In the "Data Preview" panel of any of the '''Database Table''' reference objects.
* Connecting the database table in Microsoft SQL Server Management Studio.
* Connecting the database table in Microsoft SQL Server Management Studio.


{|cellpadding=10 cellspacing=5
 
|valign=top style="width:40%"|
# Here, we have the "DB Export" '''Data Connection''' object selected.
# Here, we have the "Employee_Report_Earnings" '''Database Table''' reference object selected.
# You can see in the "Data Preview" window, now there's data there!
# You can see in the "Data Preview" window, now there's data there!
#* This is information Grooper collected and exported, using the '''''Data Export''''' table mappings we configured for the "Employee Report" '''Document Type's''' '''''Export Behavior'''''.
#* This is information Grooper collected and exported, using the '''''Data Export''''' table mappings we configured for the "Employee Report" '''Document Type's''' '''''Export Behavior'''''.
|
 
[[File:Data-export-how-to-export-behaviors-31.png]]
[[File:2023_Data-Export_02_HowTo_04_Applying-the-Export-Activity-and-Reviewing-the-Results_03.png]]
|-
 
|valign=top|
 
Using SQL Server Management Studio, we can also verify the data was exported.
Using SQL Server Management Studio, we can also verify the data was exported.


# This is the exact same database table we have selected.
# This is the exact same database table we have selected.
# Running a SELECT statement, we can see the exact same data we saw from Grooper is present in the database.
# Running a SELECT statement, we can see the exact same data we saw from Grooper is present in the database.
|
[[File:Data-export-how-to-export-behaviors-32.png]]
|}
</tab>
</tabs>


[[Category:Articles]]
[[File:2023_Data-Export_02_HowTo_04_Applying-the-Export-Activity-and-Reviewing-the-Results_04.png]]
[[Category:Version 2021]]

Latest revision as of 13:01, 3 March 2025

This article is about an older version of Grooper.

Information may be out of date and UI elements may have changed.

202520232021

Data Export is an Export Definition available when configuring an Export Behavior. It exports extracted document data over a database Data Connection, allowing users to export data to a Microsoft SQL Server or ODBC compliant database.

About

You may download and import the file(s) below into your own Grooper environment (version 2023). There is a Batch with the example document(s) discussed in this tutorial, as well as a Project configured according to its instructions.
Please upload the Project to your Grooper environment before uploading the Batch. This will allow the documents within the Batch to maintain their classification status.

The most important goal of Grooper is to deliver accurate data to line of business systems that allow the information to be integrated into impactful business decisioning. Tables in databases remain, to this day, one of the main vessels by which this information is stored. Data Export is one of the main ways to deliver data collected in Grooper.

Data Export allows us to take a document...

...and its extracted data...

...and map that data to column locations in a database table.


There are three important things to understand when using and configuring Data Export to export data to a database:

  • The Export activity.
  • Data Elements
  • Data Connections

The Export Activity

Grooper's Export activity is the mechanism by which Grooper-processed document content is delivered to an external storage platform. Export configurations are defined by adding Export Type definitions to Export Behaviors. Data Export is the Export Type designed to export Batch Folder document data collected by the Extract activity to a Microsoft SQL Server or ODBC-compliant database server.

For more information on configuring Export Behaviors, please visit the full Export activity article.

Data Elements

Data Export is the chief delivery device for "collection" elements. Data is collected in Grooper by executing the Extract activity, extracting values from a Batch Folder according to its classified Document Type's Data Model.

A Data Model in Grooper is a digital representation of document data targeted for extraction, defining the data structure for a Content Type in a Content Model. Data Models are objects comprised of Data Element objects, including:

  • Data Fields used to target single field values on a document.
  • Data Tables and their child Data Columns used to target tabular data on a document.
  • Data Sections used to divide a document into sections to simplify extraction logic and/or target repeating sections of extractable Data Elements on a single document.

With Data Models and their child Data Elements configured, Grooper collects values using the Extract activity.

Depending on the Content Type hierarchy in a Content Model and/or Data Element hierarchy in a Data Model, there will be a collection, or "set", of values for varying data scope of a fully extracted Data Model's hierarchy. That may be the full data scope of the Data Model, including any inherited Data Elements inherited from parent Data Models. It may be a narrower scope of Data Elements like a child Data Section comprised of its own child Data Fields.

Understanding this will be important as Data Export has the ability to take full advantage of Grooper's hierarchical data modeling to flatten complex and inherited data structures. Understanding Data Element hierarchy and scope will also be critical when exporting data from a single document to multiple different database tables to ensure the right data exports to the right places.

Data Connections

Data Export uses a configured Data Connection object to establish a link to SQL or ODBC compliant database tables in a database and intelligently populate said tables. Once this connection is established, collected Data Elements can be mapped to corresponding column locations in one or multiple database tables. Much of Data Export's configuration is assigning these data mappings. The Data Connection presents these mappable data endpoints to Grooper as well as allowing data content to flow from Grooper to the database table when the Export activity processes each Batch Folder in a Batch.

Furthermore, not only can Grooper connect to existing databases using a Data Connection, but it can create whole new databases as well as database tables once a connection to the database server is established.

We discuss how to create Data Connections, add a new database from a Data Connection, and add a new database table from a Data Connection in the #Configuring a Data Connection tutorial below.

FYI

We have improved integration with PostgreSQL, Db2, MySQL, and Oracle using the ODBC connection type in version 2021!

While not fully supported in previous versions of Grooper, you can now connect to these data sources with a Data Connection seamlessly in Grooper, allowing for full database export operations via Data Export.

How To

In the following tutorials, we discuss an an example of how to setup an Export Behavior, using Data Export.

In this example are a couple of different document formats whose data will be collected by a single Content Model. This will help illustrate two key distinctions mentioned above.

  • The first document (the "Employee Report) will demonstrate the flattening of a data hierarchy.
  • The second (the "Personnel Information Report") will give us an avenue to export to multiple tables at once.


The example documents have already been classified and their data extracted. Before we get into Data Export configuration specifics, there's a few things we need to understand about "the story so far"

  • The forms used in this example and how they are formatted.
  • The Content Model used in this example, its Document Types and how their Data Models represent the data we want to collect.
  • The extracted index data, which will be exported to a database.

Understanding the Forms

Document 1: Employee Report

The thing to understand about this document is some of its data share a "one-to-many" relationship.

Some of the data is described as "single instance" data. These are individual fields like "Employee Last Name", "Employee First Name" and "Employee ID". For each document, there is only one value for each of these fields. These values are only listed once, and hence only collected once during extraction.

Some of the data, however, is described as "multi-instance" data. The "Earnings" table displays a dynamic amount of rows, for which there may be a varying number of data for its columns ("Code Desc", "MTD", "QTD", "YTD") depending on how many rows are in the table. There are multiple instances of the "YTD" value for the whole table (and therefore the whole document).

The single instance data, as a result of only being listed once on the document, will only be collected once, but needs to be married to each row of information from the table, in one way or another. The "one" "Employee ID" value, for example, pertains to the "many" different table rows.

This document is meant to show how to flatten data structures. While the single instance data is only collected once, it will be reported many times upon exporting to a database table.

Document 2: Personnel Information Report

The second document is essentially one big table of personnel information (name, address, email, phone number and the like).

While we ultimately want to collect data from all rows in this table, there are potentially two sets of information here. Some of it is generic personnel information, but some of it is "personally identifiable information" or PII. This information should be protected for legal reasons.

As a result, we will export collected data to two database tables (with the assumption that the second table is "protected".)

This document is meant to demonstrate how to export to multiple tables via one Export Behavior.

DISCLAIMER: The author of this article is not a lawyer.

For educational purposes we divided "Personnel Information" into two sets: "non-PII" and "PII"

  • non-PII: Employee ID, Phone Number, E-mail address, IP Address, Gender, ZIP
  • PII: First Name, Last Name, SSN, Street Number, Street Name, City, State.

DO NOT TAKE THIS TO MEAN THIS INFORMATION IS OR IS NOT PERSONALLY IDENTIFIABLE INFORMATION.

This division was done purely for educational purposes to demonstrate a concept.

PII gets tricky in the real world. For example, an IP Address would not normally qualify as PII by itself, but could when combined with other personal information. Please consult your own legal department to determine what data you're collecting is PII and should be protected more securely.

Understanding the Content Model

The Content Model provided for this tutorial is named "Example Model - Data Export". This Content Model is designed to extract the data for these two different kinds of documents, each represented by its own Document Type.

The Employee Report Document Type

  1. The "Employee Report" Document Type' represents our "Employee Report" document.
    • This is the one we will use to demonstrate flattening a data structure that shares a one-to-many relationship on the document.
  2. It has its own child Data Model with Data Elements already configured for extraction.
  3. For the individual fields, represented once in the document, there are three corresponding Data Field elements:
    • "Last Name"
    • "First Name"
    • "Employee ID"
  4. For the tabular data, a Data Table named "Earnings" is established, with four Data Column elements, corresponding to the columns on the document:
    • "Code Desc"
    • "MTD"
    • "QTD"
    • "YTD"

The Personnel Info Report Document Type

  1. The "Personnel Info Report" Document Type represents our "personnel information" documents.
    • This is the one we will use to demonstrate exporting multiple table structures to multiple databases from a single document.
  2. It too has its own child Data Model with Data Elements already configured for extraction.
  3. The "non-PII" Data Table will extract data from each table row on the document for non-protected personnel information, as described by its child Data Column elements:
    • "Employee ID"
    • "Phone Number"
    • "EMail"
    • "Gender"
    • "Zip"
  4. The "PII" Data Table will extract data from each table row on the document for protected personnel information, as described by its child Data Column elements:
    • "Employee ID"
    • "First Name"
    • "Last Name"
    • "SSN"
    • "Street Number"
    • "Street Name"
    • "City"
    • "State"
  5. This set-up uses a single table extractor to collect each row on the document, but reports it to two different Data Table objects in Grooper (the "non-PII" Data Table and the "PII" Data Table). This will ultimately allow us to parse data from these columns, and place the PII related information into a separate database.

Verifying Index Data

Before the Database Export activity can send data, it must have data!

It's easy to get in the habit of testing extraction on a Data Field or a Data Model and feel good about the results, but it must be understood that the information displayed when doing so is in memory, or temporary. When testing a Data Export configuration, it's a good idea to ensure extracted data is actually present for document Batch Folders whose data you want to export.

When the Extract activity runs, it executes all extraction logic for the Data Model tied to a Batch Folder's classified Document Type. For each Batch Folder document, it creates "Index Data" and marries it to the Batch Folder via a JSON file called Grooper.DocumentData.json.

A couple of ways to verify its existence are as follows:


Option 1

  1. First, navigate to the Batch object in the node tree.
  2. From there, click on the "Viewer" tab.
  3. Click the "Open in review page" button.


Click the "Data Viewer" tab and from there you can review review the data.


FYI

Were the document classified (the Batch Folder assigned a Document Type), but not successfully extracted (the Extract activity not applied), the data structure would be present, but the fields empty.

At that point the Batch Folder would have the Document Type's Data Model associated to it, but would not have applied its extraction logic to collect values (That's what the Extract activity is for).


Option 2

Another means of verifying is to actually view the file created by the Extract activity and stored in the Grooper repository's file store location.

  1. In this case, select a Batch Folder that is a child of the Batch. In this case the "Employee Report(1)" is selected.
  2. Click the "Advanced" tab.
  3. Select the JSON file in the files panel.
  4. Click the "Display file" button.


A new tab will open in your browser and you will be shown the contents of the JSON file. This is the file the Extract activity generates when it processes a Batch Folder. It serializes all the extracted Data Elements' values for the document's Data Model.

Configuring a Data Connection

In order for the Data Export to run, it first needs an established connection to a database and subsequent table(s).

Grooper can connect to an existing database and import references to its tables using a Data Connection object. Once connected to the database server, you can even have Grooper create a database AND create tables based on Data Model structures present in Grooper!

In the following tutorial we will cover how to:

  1. Create a new Data Connection object.
  2. Connect to a database server using the Data Connection.
  3. Create a new database from the Data Connection.
  4. Create a database table using the Data Models in our example Content Model.

It is worth noting that this article cannot tell you specifics about permissions in your own environment. The configuration for this article uses Microsoft SQL Server and has given the active Active Directory user full DB Admin privileges to the SQL environment.

Create a Data Connection

New Data Connections are added to the Global Resources folder of the Node Tree.


  1. Right click the Global Resources folder.
  2. Select "Add" then "Data Connection..."
  3. The "Add New Data Connection" window will appear.
  4. Give the new Data Connection a name.
    • We've named ours "DB Export"
  5. Press "OK" when finished.


  1. This will add the new Data Connection to the Global Resources folder.
  2. Next, we will configure connection settings so that Grooper can interoperate with our SQL server.

Configure Connection Settings

Regardless whether you want to connect to an existing database or create a new one from Grooper, your first step is always the same. You must first connect to a database server.

Grooper can connect to Microsoft SQL servers or any ODBC (Open Database Connectivity) compliant data source. For the purposes of this tutorial, we will connect to a SQL server.


  1. However, you can choose to connect to a SQL server or ODBC server using the Connection Settings property.
  2. Using the dropdown menu, choose either SQL Server or ODBC
    • Again, we will be connecting to a SQL server. So, SQL Server is selected.


Next, we need to define settings to access the database server. All you really need to do this is the server's name and access rights.

  1. Expand the Connection Settings property.
  2. Using the Server Name property, enter the SQL server name.
    • I was a little on the lazy side for this article and just connected to the SQL Express instance created for the Grooper repository database on my local machine. This is almost assuredly not what you want to do in a production environment, but it will work for testing purposes.
  3. You will also need access rights to the SQL server. Using this Data Connection object, Grooper is going to act as if it were a user, giving Grooper the capabilities to do things like add and drop tables, run queries, and more. Just like a user needs SQL access credentials, so does Grooper.
    • If the active Windows user has Active Directory rights to the SQL server, Windows will pass through your credentials. You can leave the User Name and Password blank in that case.
    • Otherwise, you'll need to enter a User Name and Password to access the database server here.
  4. Go ahead and hit "Save" at this point.


That's it! You're officially connected to the database server now. We can now connect to existing databases, import references to their tables (Keep this in the back of your mind. This will be important later.), create new databases, and new database tables.

Create a New Database from the Data Connection

At this point, you have two options:

  1. Connect to an existing database
  2. Create a new database

If you wanted to connect to an existing database, it's very easy.


  1. Select the Database Name property.
  2. Either type in the database's name or select it from the drop down menu.
    • FYI: Grooper has to ping the database in order to populate the dropdown list. Depending on the size of your SQL server, it's often quickest to just type in the database name.


However, now that we're connected to the database, you can also create a brand new database!

Create a New Database from the Data Connection
  1. To create a new database, press the "Create Database..." button.
  2. This will bring up the "Create Database" window.
  3. Using the Database Name property, name the database whatever you like.
    • We named ours "Export_Example_DB"
  4. Press the "Execute" button to create the database.


  1. You will see the newly created database's name populate the Database Name property.
  2. However, as a newly formed, infant database, it has no database tables. You can see, the "Database Tables" panel is empty. Next, we will add some database tables using the data structures of the Data Models in our example Content Model.


FYI

If you connect to the server in Microsoft SQL Management Studio, you can verify the database is created.

See here, the "Export_Example_DB" is added to the list of databases. Through the Data Connection Grooper has a direct connection to this SQL environment to add and alter databases.

Create Database Tables from the Data Connection

We will end up creating three database tables by the end of this section:

  1. A table for the "Employee Report" Document Type's extracted Data Elements with its "one-to-many" related data elements flattened to a single table structure.
  2. A table for the "Personnel Info Report" Document Type's extracted "non-PII" Data Table.
  3. A table for the "Personnel Info Report" Document Type's extracted "PII" Data Table.
Table 1: Employee Report Data
  1. To create a new database table, press the "Create Table..." button.
  2. This will bring up the "Create Table" window.
  3. Database tables are created from Grooper using Data Elements from a Data Model. The Data Model's Data Fields and/or Data Columns will form the columns of the SQL table, housing extracted values from each document folder upon export. First, you must define the Content Type (e.g. a Content Model or one of its Document Types) whose Data Model you want to use to create the database table.
  4. The Data Element property's dropdown menu will present you a mini Node Tree view to select a Data Container from your Data Model.
    • In our case, we will select the "Earnings" Data Table from our "Data Export - Content Model"'s Data Model.
    • Why didn't we choose the parent Data Model? It's all about Data Model hierarchy and scope. We want access to all the Data Elements in the "Earnings" Data Table. If we chose the parent Data Model, we would only have access to its immediate Data Elements, which would not include any of the Data Elements we want to export.


For the way we will want our table structured, we will need to consider the Create Mode property. In the case of the "Earnings" table, Simple would create a table based only on the this one table's structure. Recursive is for more complex tables that have interconnected referencing, which this does not have. However, Flatten will be our best option. This will take the information from the Data Columns from this table, and flatten it with Data Fields that are siblings to the parent Data Table. In this case, there are three Data Fields in the "Header Info" Data Section, which is a sibling to the "Earnings" Data Table. These three fields will be flattened into a single row of information with the other Data Columns from the "Earnings" Data Table.

  1. Click the drop-down for the Create Mode property.
  2. Select the Flatten option.


  1. Here's where Grooper is doing the hard work for us. Notice in the "Review/Edit SQL Statement" window the SQL Statement required to create our table is already written for us.
  2. However, you can edit this statement, if need be.
    • For example, at the time of writing this article there was a bug involving the "Employee ID" Data Field. It's Value Type in Grooper is set to Int16. This was not properly converting to a "smallint" SQL data type for the corresponding SQL column. So we added smallint to the SQL Statement after [Employee ID].
  3. Click the "Run SQL Statement" button to create the table.


  1. Upon successfully creating the table, the "Database Tables" panel will have our newly created table listed.
    • It will initially display with a red dot on the icon. This will change to a green dot when we import this table's reference (more on that later).
  2. The "Table Columns" panel will display the data structure of the table, listing the SQL table's columns, their data types and other information.
  3. The "Data Preview" panel will display data within the table.
    • Because this table was just created, it will not have any data to display. We haven't exported any data to it yet!

Table 2: Personnel Info Report non-PII Data

For the other two tables, it's mostly a repeat of the same steps, just taking care to select the appropriate Content Type and Data Element scope.


  1. To create the second database table, right-click the Data Connection and choose "Create Table".
  2. Click the drop-down for the Data Element property ...
  3. ... and choose the "non-PII" Data Table.
  4. Click the "Execute" button.
    • We don't need to worry about the Create Mode property in this case as we only need the contents of the selected Data Table. Simple would be a perfectly fine setting, and is technically more accurate here, but leaving it at Flatten won't technically do anything.


  1. Success! The table is now successfully created.

Table 3: Personnel Info Report PII Data

This database table can be created with the exact same steps as described above with just one key difference:


  1. The Data Element property will be set to the "PII" Data Table not the "non-PII" Data Table.


We now have our third database table added to the SQL database.

Configuring Export Behaviors for Data Export

Data Export is one of the Export Type options when configuring an Export Behavior. Export Behaviors control what document content for a Batch Folder is exported where, according to its classified Document Type. As such, in order to configure a Data Export, you must first configure an Export Behavior for a Content Type (a Content Model or its child Content Categories or Document Types).

In our case, we want to perform two different kinds of export, depending on the document Batch Folder's classified Document Type.

  • For the "Employee Report" Document Type, we want to export its collected Data Elements to our first database table.
  • For the "Personnel Info Report" Document Type, we want to export its collected Data Elements (which are collected using an entirely different Data Model and have an entirely different data structure) to our second and third database table.

The basic idea behind Export Behaviors is, based on kind of document you're looking at, you can tell Grooper how you want to export it.

Export Behaviors can be configured in one of two ways:

  1. Using the Behaviors property of a Content Type object
    • A Content Model
    • A Content Category
    • Or, a Document Type
  2. As part of the Export activity's property configuration

When the Export activity processes each Batch Folder it will execute the Export Behaviors, according to their configuration settings.

FYI

In general, users will choose to configure Export Behaviors either on the Content Type object it applies to or local to the Export activity step in a Batch Process.

This may just boil down to personal preference. There is no functional difference between an Export Behavior configured on a Content Type or an Export Behavior configured on an Export Step, upon completing their configuration. In either case, they will accomplish the same goal.

However, it is possible to configure Export Behaviors, in both locations. If you do this, you will need to understand the Export activity's Shared Behavior Mode property options. This will effect if and how two Export Behaviors configured for the same Content Type will execute. Please visit the Export article for more information.

Add an Export Behavior

Option 1: Content Type Export Behaviors

An Export Behavior configuration can be added to any Content Type object (i.e. Content Models, Content Categories, and Document Types) using its Behaviors property. Doing so will control how a Document Type "behaves" upon export.

  1. Select the Content Type whose Export Behavior' you want to configure in the Node Tree.
    • We will start by configuring an Export Behavior for the "Employee Report" Document Type.
  2. To add an Export Behavior, first select the Behaviors property.
  3. Then,m press the ellipsis button at the end of the property.

  1. This will bring up the Behaviors collection editor window.
  2. Press the "Add" button.
  3. Select Export Behavior.
    • FYI: Children Content Type objects will inherit export settings from their parent Content Type's Export Behavior configuration
    • Also, you can only configure one Export Behavior per Content Type object. However, you can configure an Export Behavior for any Content Type in a Content Model. Functionally, this is how you add multiple Export Behaviors for a single Content Model.
      • For example, our two Document Types need different Export Behavior configurations. We would 'not want to configure their parent Content Model's Export Behavior. That would apply that single export configuration to all Document Types. That's not going to work for us. The "Employee Report" documents' data need to go to one location and the "Personnel Info Report" documents' data need to go somewhere entirely different. Instead, we will end up configuring the Behaviors property of both Document Types individually. Thus, we end up with two Export Behavior configurations for the Content Model.

  1. You will see the Export Behavior added to the Behaviors list.
  2. Selecting it, you can now add one or more Export Definitions with the Export Definitions property.
    • Next, we will add a Data Export definition.

Option 2: Export Activity Export Behaviors

Export Behaviors can also be configured as part of the Export activity's configuration. These are called "local" Export Behaviors. They are local to the Export activity step in the Batch Process.

PLEASE NOTE that the following instructions are only to be followed if you choose to set Export Behaviors on the Batch Process Step instead of on the Content Type itself. You do not need to follow these instructions if you choose to set the Export Behaviors on the Content Types, which is how this article will continue. It's worth understanding that if you set Export Behaviors on Content Types themselves, you as a result do not need to choose which Content Type the Export Behavior will apply to. However, when setting Export Behaviors on Batch Process Steps, the first thing you configure after adding the Export Behavior is which Content Type the behavior should apply to. You can set multiple Export Behaviors that affect multiple Content Types on the Batch Process Step, or you can configure individual Export Behaviors on individual Content Types. Again, in the case of this article, we will be setting the Export Behaviors on each Content Type, instead of on the Batch Process Step.

  1. For example, here we have a working Batch Process selected in the Node Tree.
    • This is a simple Batch Process that could have been used to process these documents, recognizing their text, classifying the document Batch Folders, and extracting data from them. The last step in this Batch Process is an Export step.
  2. Select the Export step of the Batch Process.
  3. To add an Export Behavior, select the Export Behaviors property.
  4. Then, press the ellipsis button at the end of the property.


  1. This will bring up the Export Behaviors collection editor window.
  2. Press the "Add" button to add a new Export Behavior
  3. An Export Behavior will be added to the list.
  4. With the Export Behavior selected you must define which Content Type the behavior applies to using the Content Type property.
    • Note in both cases, a Content Type is involved in configuring Export Behaviors.
    • Whether local to the Export activity or as part of a Content Model's configuration, Grooper needs to know what to do upon export, given a certain Content Type. Once Grooper knows what kind of document it's looking at, we can then inform it what to do in terms of exporting its document content.
  5. Using the dropdown menu, select which Content Type scope should utilize the Export Behavior by selecting either a top-level parent Content Model or one of its child Content Categories or Document Types.
    • Keep in mind you can only select a single Content Type here. You can only configure one Export Behavior per Content Type object.
    • Again, children Content Type objects will inherit export settings from their parent Content Type's Export Behavior configuration. However, multiple Export Behaviors may be added locally to the Export activity.
      • For example, since both our Document Type needed a unique Export Behavior configuration, we would add one Export Behavior to the list for each one.


  1. Here, we have selected the "Employee Report" Document Type. This Export Behavior would then only apply to Batch Folders of this Document Type.
  2. Once a Content Type is selected, you can add one more more Export Definitions with the Export Definitions property.
    • We will discuss adding a Data Export definition next.
  3. Click the "+" button.

Add an Export Definition

  1. We will choose to configure the Export Behavior using "Option 1", adding it to the "Employee Report" Document Type
  2. We will add the 'Export Behavior to its set of Behaviors properties.


Regardless if you choose to configure the Export Behavior on a Content Type object, or if you configure it local to to Export activity's configuration, your next step is adding an Export Definition.

  1. Once you've added an Export Behavior, select the Export Definitions property.
  2. To add an Export Definition, press the ellipsis button at the end of the property.


  1. This will bring up an Export Definition list editor to add one or more Export Types.
    • Next, we will add a Data Export definition to the list.

Add a Data Export

Export Definitions functionally determine three things:

  1. Location - Where the document content ends up upon export. In other words, the storage platform you're exporting to.
  2. Content - What document content is exported: image content, full text content, and/or extracted data content.
  3. Format - What format the exported content takes, such as a PDF file or XML data file.


Export Definitions do this by adding one or more Export Type configurations to the definition list. The Export Type you choose determines how you want to export content to which platform. In our case, we want to use a Data Connection to export extracted document data ("Content") to a database table ("Location" and "Format"). We will add a Data Export to the definition list.

  1. To do this, press the "Add" button.
  2. Choose Data Export from the list.


  1. This will add an unconfigured Data Export to the Export Definitions list.
  2. For all Data Export configurations, the first step is configuring the Connection property.
  3. Use the dropdown menu to select a Data Connection from the node tree.
    • This will provide Grooper with the information required to connect to the external database upon export.


  1. With the Data Connection established, the next step is to map data from Grooper to a table in the database.
  2. Next, we will review using the Table Mappings property to map Data Elements in a Data Model to corresponding column locations in a database table.

Table Mappings Example 1: Flattening a Data Model

We will continue configuring our "Employee Report" Document Type's Data Export first. For this document, we have to deal with a "one-to-many" relationship between data that exists once on the document, and the dynamic data in the multiple rows in the "Earnings" table.

For this example, we will flatten the Data Model's element hierarchy. By flattening the Data Model, we can output all the document's data to a single database, despite the fact some of its data is present once on the document (the single instance Data Field' values) and some is more dynamic (mutli-instance Data Column values from our Data Table).

We will essentially re-output the single instance values, marrying them to every row instance output for the table on the document. Think of the single instance values as "document level". These single values ("Last Name", "First Name", "Employee ID") pertain to the whole document. Therefore, they also pertain to every row of information in the "Earnings" table.


We accomplish this feat through Table Mappings. This will allow us to hook up the right Data Elements in a Data Model to the right database table columns upon exporting collected values. Much like data hierarchy scope was important when we created this database, so will it be when we configure Table Mappings for export.


  1. With the Data Export selected, select the Table Mappings property.
  2. Press the ellipsis button at the end.


  1. This will bring up the "Table Mappings" collection editor.
  2. Press the "Add" button to add a new set of mappings.
  3. Use the Source Scope property to select the appropriate Data Element scope in the Content Type's Data Model.
  4. In our case, we're choosing the "Earnings" Data Table.
    • Selecting this Data Table as the scope will not only allow mapping to its Data Columns, but all Data Fields up its logical hierarchical tree path (i.e. "Last Name", "First Name", and "Employee ID").


Next we need to define which database table we're mapping to. There are now three databases in the database connected to our Data Connection. Each of their table references have been imported to Grooper. We need to pick which one we want to use.


  1. Choose which database table you want to map using the the Target Table property.
  2. Select a database table using the dropdown menu.
    • In our case the "Employee_Report_Earnings" database table.
    • FYI: Without importing the database table's reference, creating the child Database Table object for our Data Connection, you would not see the database table listed here.


Now that we have a source data scope selected (where we're mapping from) and a target database table selected (where we're mapping to), we will map the Data Elements in our Data Model's scope to columns in the targeted database table.


  1. Select the Column Mappings property.
  2. Press the ellipsis button at the end.


  1. This will bring up the "Column Map" editor.
  2. Each database table column will be listed as a property in the grid.
  3. Using the dropdown menu, you can select a corresponding Data Element from the Data Model's scope.
    • FYI: Since we selected the "Earnings" Data Table as our scope, its direct children are listed as their simple Data Element names. For example, "MTD" for the "MTD" Data Column.
      • For Data Elements inherited from a parent scope, they will be listed as "Scope Source"."Data Element". For example, the "Last Name" Data Field was inherited from the "Employee Report" Document Type's base Data Model. So, it is listed as "Employee_Report.Last_Name".
    • For the Last Name database column, we have selected the Employee_Report.Last_Name Data Element.


There is also a mapping shortcut to automatically assing mappings if a Data Element's name matches a database column's name.

  1. Right-click any property in the grid.
  2. Select "Auto-Map..."


  1. Database table columns will be automatically mapped to Data Elements as long as their names match.
    • Furthermore, since we created this database table from Grooper, using the same Data Model, all of these column names and Data Element names will match.
  2. Press "OK" to finish configuring mappings.


We now have everything we need to export data from "Employee Report" documents to a database, using Data Export.


  1. Press "OK" on this and all subsequent windows to finalize the Export Behavior configuration.
  2. Don't forget to save the Content Type when you're done.

With this Export Behavior in place, whenever the Export activity processes an "Employee Report" Batch Folder, data will be exported to the database as we've designed through these settings.

Before testing the Export step, in the next tab, we will configure another Data Export for the "Personnel Info Report" Document Type with its own set of database table mappings to export their extracted data to two different database tables.

Table Mappings Example 2: Exporting to Multiple Database Tables

Despite the fact you can only set up one Export Behavior per Content Type, you can add as many Export Definitions as you need.

In this example, we will take the extracted data from our "Personnel Info Report" Document Type and export PII information to one database table and non-PII information to a different table, using two Data Export definitions.


  1. We want to export data for the "Personnel Info Report" documents. We will configure the Export Behavior' using the "Personnel Info Report" Document Type.
  2. We've already added the Export Behavior to the Behaviors collection list.
  3. We've added a single Data Export definition.
  4. We've already pointed the Connection property to our "DB Export" Connection Type.
  5. Next, we will assign the Table Mappings.


  1. Using the "Add" button, we've added a Table Mapping for the first of the two Data Table elements used to collect information from the report..
  2. For the Scource Scope, we've selected the "non-PII" Data Table.
  3. We want to all the data Grooper collects for that Data Table to the "Personnel_Info_Report_non_PII" database table. We have selected that database table for the Target Table.
  4. All that's left is to assign our Column Mappings.


  1. Next, we mapped our source Data Elements (The Data Columns in the "non-PII" Data Table in this case) to our target database table columns.
    • Since the names all matched, we just used the "Auto Map" feature.
  2. Press "OK" to finish.


Now we just need to set up mappings for the "PII" Data Table. In this case, we're exporting to the same database, just two different database tables within it. Since we're already collecting mappings for the database connected to using the "DB Export" Data Connection, all we need to do as add another set of Table Mappings.


  1. Press the "Add" button to add a new set of mappings.
  2. For the second set of mappings, we've selected the "PII" Data Table for the Source Scope.
  3. Using this mapping, will push the extracted PII information to the "Personnel_Info_Report_PII" database table, which we have selected for the Target Table.
  4. Last but not least, we've mapped our source Data Elements to their target database table columns using the Column Mappings property.

FYI

Here, we added two sets of table mappings to two database tables in the same database. What if you wanted to add two sets of mappings to database tables in different databases?

That's easily doable. You would need two Data Connections, one to connect Grooper to each individual database. Then, you would need to add two Data Export definitions, each one using one of the two Data Connections. From there, you'd add the individual table mappings to each individual Data Export.


We now have everything we need to export data from "Personnel Info Report" documents to two tables in a database, using Data Export.


  1. Press "OK" on this and all subsequent windows to finalize the Export Behavior configuration.
  2. Don't forget to save the Content Type when you're done.

Next, we will apply the Export activity to the document Batch Folders in our sample Batch, which will export data according to their Document Type's Export Behavior using the Data Export definitions.

Applying the Export Activity and Reviewing the Results

Process the Export Step

With the two Export Behaviors configured, we can now test our export. Export Behaviors are executed by the Export activity.


  1. We will use this example Batch Process to demonstrate our Data Export configurations detailed in the previous tutorial.
  2. The Export activity in our Batch Process will apply our Export Behavior to every Batch Folder in the Batch.
  3. FYI: Because we configured the Export Behavior on Content Type objects (using the two Document Types' Behaviors property editor), we do not have to configure the Export activity's local properties.
    • We've given Grooper all the information it needs to export content. The Export activity will go through each Batch Folder in the Batch. It will see the Batch Folders are classified with one of the Document Types in our Content Model and use their Export Behavior configuration settings to export document content.


We will test our export using the Export activity's "Unattended Activity Tester" tab.


  1. Expand the Batch Process to reveal its child Batch Step nodes.
  2. Select the Export activity step.
  3. Switch to the "Activity Tester" tab.
  4. Select the documents at the appropriate scope, and press the "Test the Activity" button.
    • You could also select the "Data Export - Batch" root "Batch Folder" and use the "Submit a job" button to process these documents through a job, which will allow it to funtion with multiple threads.

Review the Export

You can easily review our exported data in one of two ways:

  • In the "Data Preview" panel of any of the Database Table reference objects.
  • Connecting the database table in Microsoft SQL Server Management Studio.


  1. Here, we have the "DB Export" Data Connection object selected.
  2. You can see in the "Data Preview" window, now there's data there!
    • This is information Grooper collected and exported, using the Data Export table mappings we configured for the "Employee Report" Document Type's Export Behavior.


Using SQL Server Management Studio, we can also verify the data was exported.

  1. This is the exact same database table we have selected.
  2. Running a SELECT statement, we can see the exact same data we saw from Grooper is present in the database.