Demo presentation text:
Hello, this is a demo about the migration tool provided by Ispirer Systems for the conversion from COBOL to C #. NET.
In this demo we will talk about one of possible options to convert Record and File Description statements.
We will use SQLWaysCommander tool provided by Ispirer Systems.
On the left panel I am opening the folder with our source file and choose COBOL as a source language.
On the right panel, we should create and select a folder for conversion results and choose C# as a target language.
Have a look at the example of the source code.
As you can see, it contains a declaration of FD statement to read data from the file, Record Stuff and some statements for manipulation with them.
Record Stuff is a complex record including examples of sub-levels and redefined construction. It is a file with input data.
Let's try to compile this example. To do this, we will use the Open-Cobol tool.
I am running and here you can see the result.
Now we will run the conversion. On the bottom panel you can see the progress. After compilation on the right panel we see the results, this is a converted COBOL program and generated classes used for work.
Let’s have a look at the code.
As you can see COBOL program is converted into a class, containing the method Execute for running business logic. Sections in Procedure Division are converted to class methods. Class EntityStorage generated for FD statement. Record Stuff is converted to the separate class that provides data processing using the generated classes.
Let’s check it. To do this, we open Visual Studio and create a new console project.
Then we add files with the conversion results and the input data file to the project.
Let's try to run our C# application: we need to call the Execute method from function Main.
We can compare the results. They are identical.
The result code is formatted, ready for use, further development and refactoring. If you have a solution for converting COBOL to C# or have a project on COBOL with specific logic, conversion can be easily customized.
That is all I wanted to tell you in this Demo. Other conversion solutions from COBOL to C# will be shown in our next Demos. The information about other tools that Ispirer Systems provides for database migration support is available on our website. I hope this Demo was useful. Thank you for your attention!