Article

Data Import into OutSystems

February 11, 2022

Copying Legacy data into OutSystems

Many companies [1][2][3] are migrating older technology solutions into this amazing Low-Code platform that is OutSystems – from Lotus Notes [4] to Domino to many other legacy solutions, perhaps even some made ad-hoc with “latest tech" that some developer wanted to try and that ended up an orphan in the company’s technological landscape.

if you’re replacing a legacy app with OutSystems you don’t want to keep its database around, but most probably you need its data

Companies need to innovate, and not only survive but thrive in a competitive environment, and that means being able to implement solutions for mobile, with the advantages of the cloud, with seamless integration, offering users omni-channel flows, searching for the best customer experiences (CX) evolving standards, while making sure security & compliance are assured – and OutSystems, Low-Code leader by Gartner [5] and for several year’s their Customer’s Choice [6] in the low-code environment, fills this need.

However, OutSystems has no built-in data migration tool, no way to copy data between OutSystems instances – and being low-code, there are some limitations and risks on moving data around, since you have to guarantee consistency with its metadata structure [7].

OutSystems has no built-in data migration tool

If you want to directly connect to the external database, or if you are importing data from an Excel file into a single entity, OutSystems can out-of-box provide it [8], but if you’re replacing a legacy app with a minimally connected data structure, you probably don’t want to keep its database around with an external connection – you want to bulk import that data into OutSystems entities, to be able to use the power of your new platform to the fullest!

In this scenario, when importing data from non-OutSystems solutions, you have to overcome 2 challenges:

  1. How to connect to (your specific) external database
  2. How to guarantee in the import process all the data consistency (keys, relationships between entities, circular references, etc.) needed, with the correct OutSystems database metadata definition.

Fortunately you can find in the OutSystems Forge the Data Migration Manager (DMM) [9] component, that offers for free the ability to import data from any non-OutSystems source!

DMM will give you the specs on how data must be setup to be imported to your OutSystems app, execute with a simple 3 step wizard the import while seamlessly guaranteeing all data consistency in OutSystems!

Data Migration Manager (DMM) component offers for free the ability to import data

DMM has the capability to fully guarantee data consistency, either while migrating data between OutSystems instances (for DevOps use-cases [11], for example, or when migrating OutSystems OnPrem <=> Cloud) or when importing data from non-OutSystems solutions into OutSystems.

DMM guarantees all technical and business aspects without the user (you) having to worry or do complex configurations. For example it guarantees “under-the-hood" things like: identifying the current physical tables, active fields/columns, FK relationships defined in the metadata, circular references, data types, the order of records for the import process (inserts/updates needed), management of PK fields (even when auto numbered fields) [10], etc..

How to import legacy data into OutSystems with DMM

You follow a 3 step approach to get your data into the OutSystems entities of your application.

First step, you use DMM Export feature to get a list of CSV files, one file for each entity in your OutSystems application. These CSV files don’t have any data, just the first line (header) with the name of the fields/columns expected by your OutSystems application for that entity.

The exported ZIP, besides the entity CSV files, has several other files that DMM will use later in the Import feature to guarantee the data consistency. You will not edit or change these other files.

Second step, you go to your legacy application database, and export (using any ETL tool that is compatible with your legacy solution) the data into CSV files with the exact structure that DMM gave you in the previous step.

You add these CSV files into the previously exported ZIP, replacing the original CSV files.

Third step, you use the DMM Import feature to load the ZIP file:

And that’s all, DMM will create the SQL scripts needed to execute the import guaranteeing the correct physical tables, active fields/columns, that connections/FKs are maintained (even circular or self references), serialized binaries and other datatypes.

In the end, you will find all your original data in the OutSystems entities, available to your new OutSystems applications!

References:

[1]https://www.outsystems.com/case-studies/accelerate-development-low-code-approach

[2]https://www.outsystems.com/case-studies/mazda-legacy-migration-to-save-millions/

[3]https://www.outsystems.com/case-studies/fast-development/

[4]https://www.outsystems.com/use-cases/notes-rebuild/

[5]https://www.outsystems.com/1/low-code-application-platforms-gartner-/

[6]https://www.gartner.com/reviews/market/enterprise-low-code-application-platform

[7]https://success.outsystems.com/Support/Enterprise_Customers/Maintenance_and_Operations/Data_Migration_From_Production_to_Non-Production_Environment/OutSystems_Platform_Metamodel

[8]https://success.outsystems.com/Documentation/11/Extensibility_and_Integration/Extend_Logic_with_Your_Own_Code/Managing_Extensions/Define_Extension_Entities/Import_Entities_from_a_Database

[9]https://www.outsystems.com/forge/component-overview/2812/infosistema-dmm

[10]https://www.infosistema.com/outsystems-entity-field-keys-linked-to-external-systems/

[11]https://www.infosistema.com/devops-testing-as-an-enabler-for-faster-app-releases-high-quality-sw/

infosistema Inet