---
title: "Importing Data"
canonical: "https://servicedesk.maxgeo.com/space/LogChief/1275887749/Importing%20Data"
format: markdown
---
LogChief allows data to be imported from a data source into LogChief's logging databases to be used during logging in the field.

We recommend that while logging offline, (i.e. connecting to a local configuration as opposed to the Server Configuration) only a portion of the database data should be imported. This is due to the fact that the vast amount of data may reduce the performance of LogChief.

To import data from the Main Database or from an XML file, click on one of the following options

![image](media://bbd26669-5625-4291-a07c-6f6b9303e5df)

***Note****: Lik e the export function, imported data is not Profile specific. Data is imported into any table in the Configuration database which can then be accessed by any of the Profiles.*

## **Importing Data from Database**

To import data from an MDS database, the user has two options.

Import data for Configuration Tables i.e. the tables included in the configuration

Import data for any MDS table which has a DataSet column

**Import on the basis of Dataset**

This function allows for the user to import data from non-Configuration tables (i.e. MDS data from tables not selected for logging in the Configuration) into the Configuration database. For example, Assay data and Map shape files produced in MapInfo or ArcGIS can be used with an MxApp such as StripLog.

Click on  to open the Import Data window. Select the required Dataset through the tree layout and the table from which to import the data and click on 'Import'.

![image](media://5263ec47-6eb4-44d4-a874-9709fe2497af)

The "Select all Config Tables" option will select all the tables from current Configuration.

"Lock Records" option will Lock the imported records and the user will not be able to modify the record. By default, it will have a synchronized status.

**Import Data to view in LogChief**

Import historically logged data from the MDS into Tables selected in the Configuration Wizard. Data can be imported on the basis of Hole ID's or Sample ID's (for surface samples) so that individual holes/samples may be selected for importing. This data can then be edited/modified in the logging views or used purely as historic data to view in Striplog.

Select the   icon on the main screen of LogChief to navigate to the Import Data window:

![image](media://d7a0364e-f88e-4c7f-a65d-d9e63893538f)

**Add Import Filter**

To add an import filter, click the Add button to load the Filter Builder.

Filters are the queries which bring the data from the database.

![image](media://8cd48a38-4ab1-45e8-8445-5ff7f93d95cb)

A Filter can be created by Mapping or by Individual table.

<span style="color: #b12d2c">***By Mapping***</span>

Import filter will be created for all the tables in the mapping selected by user. User can create a where clause for a Parent table and that where clause will be applied to a child table.

<span style="color: #b12d2c">***By Individual Table***</span>

Filter will be created for individual table. This option allows the user to select which columns to import and to build advanced where clauses.

In the example above, the filter being created will import data for all tables in the Collar Mapping where the Hole_Type is equal to DDH (i.e. only import Diamond Drill Holes).

Click on ‘*OK’* to continue with the import which will bring you back to the *Import Data* window where the newly created filter will be displayed.

*These filter can be cascaded depending on the setting in*<span style="color: #0000ff">* *</span><u><span style="color: #0000ff">*[Options window](#page197)*</span></u>*.*

<span style="color: #b12d2c">***Locking Records***</span>

To prevent users from altering the imported data (i.e. make imported data read-only), select the Lock Records option.

**Edit Import Filter**

To edit an existing filter, select the filter and click the Edit button. This will bring you to the 'Build Filter' window where you will be able to edit the filter.

![image](media://dc33dc3f-d0b4-487e-a9a6-87b2d23f4860)

**Remove Import Filter**

To remove an existing filter, select the filter and click the Remove button.

![image](media://68b87c89-26a2-4c0f-93ad-cd50deaebbbd)

**Load Import Filter**

To load saved filters, click on the Load button and select which filters to load from the list.

![image](media://0d4dc04f-bb56-4fd1-97aa-8be1c5c7e014)

**Saved Filters**

Filters can be saved so they can be loaded at a later date.

To manage the saved filters, click on the Saved Filters button.

Create, edit or delete import filters using the New, Edit and Delete buttons.

![image](media://77f5842b-f655-41a1-8048-67bcb7dd1204)

## **Importing Data from XML**

LogChief allows logged data to be exported to an XML file using the Export Wizard. This data can then be imported into another LogChief instance using the XML option in the Import Data tool.

To import data from an XML file, simply select the   icon in the top toolbar in the main LogChief window and browse to the source XML file and click the Import button.

***Note****: As long as the back end Database is of the same format in the importing Configuration as in the exporting Configuration (i.e. same table and column names and data types), then the data will be imported. If there are structural differences then you may receive errors.*

*Importing from XML only imports into tables selected for logging in the 'Configuration Wizard'. If any data in the XML file belongs to a 'non-selected' table in the importing Configuration, then this data will not be imported - all other data in the file will still be imported. This will not generate an error so be aware of which tables are required and which are selected in the Configuration.*

![image](media://aad97abd-1e47-4e5f-903c-21757b75cb7c)

## **Import Contracts**

Click on the ***Import Group > Import**** Contracts* menu item in the main window of LogChief to open Import Contract Screen.

This option is only available for MDS 4.6.2 SP1 or later versions.

![image](media://68e98450-e45f-4f0f-822b-7c333c6a9c16)

The following screen will allow a user to import Contract data for the specified four tables along with all the other tables referenced by these tables.

![image](media://82522e6e-e6d9-4c64-824d-a8e4f7b1fc23)

"Lock Records" option will Lock the imported records and the user will not be able to modify the record. By default, it will have synchronized status. This will only happen if the above mentioned tables are used in any of the configuration mapping.