MAPPING Suite and Oracle


MAPPING Suite: Printing Solutions For All ERPs


Connecting to an Oracle instance

To connect to an Oracle instance, you need to configure the MAPPING environment to use the Oracle listener by specifying the instance, user name and password in the environment settings.

Creating the document in MAPREPORT

The first step in creating a document with MAPREPORT is to specify the input settings and to build the tables containing the data by typing the SQL queries and defining the field names and types. Alternatively, you can also create definition files for existing tables from the MAPPING Web interface. Then, the tables are added to the report. We usually create the base report using a main query that loads the information into a temporary table.

Then, you need to define the different blocks that make up the report. It is usually recommended to fill out the first 10 columns with conditional codes that can be used to simplify the design of the template. 

Once the blocks are set up, the document takes shape and the last thing is to add calculations and specify how page breaks occur. In addition to SQL queries, one can also use Oracle functions and stocked procedures in calculation zones in MAPREPORT.

Example SQL calculation:
SELECT " FIELD_NAME from map_structure_organisation where code_site=" $DB.MA_VAR1 "

Example calculation with a function:
SQL "BEGIN : myvariable := PACKAGE_NAME.FUNCTION_NAME( " $DB.MA_VAR1 "," $DB.MA_VAR2 ");END;"

Example calculation with a stocked procedure:
PARAM ( $DB.RESULT , $DB.RESULT2) SQL "BEGIN PACKAGE_NAME.PROCEDURE_NAME ($ DB.MA_VAR1 , ":param1 , :param2 ) ; END;"
Mapping oracle ebusiness schema

Creating the layout in MAPDRAW

Once the document report is set up, the next step is to design the layout:

  • Designing the overlay that contains static objects such as tables and logos, etc.
  • Setting up the layout - i.e. data mapping - that contains variable zones and groups.

Production Mode

To generate and print this document, one needs to run the MAPRUNRPT command to first generate the document in the TXT format and then run the MAPCPYSPLF command to apply the new formatting in the selected print language. According to the type of report, there are different ways of creating a document:

  • Users can be granted the right to generate their own documents via a dedicated menu in MAPREPORT. This menu can contain variables initlialized by SQL, a Shell or values. Once the variables are initialized a script generates and remaps the spool file in the desired outqueue.

  • We can use a script to create the output TXT files using the MAPRUNRPT command and then the rules engine to remap the files and redirect them to the correct outqueues.

  • Oracle Triggers can be used in many different ways for example to create a settings file in an entry point. This file will allow you to use the rules engine.