Mertech Blog

Server Side License Control View for the Oracle (ORAFlex) Driver

Written by Marcello Yo | Aug 17, 2012 2:51:00 PM

Mertech’s Oracle driver for DataFlex allows existing DataFlex applications to connect to an Oracle database server without requiring application level changes. The Oracle driver uses the Oracle Call Interface (OCI) for communicating and accessing the Oracle database, which is much faster than using an ODBC-based product.


After downloading and installing the Flex2SQL Migration tool, you need to create the Server Side License Control View at your Oracle server before performing a migration.

Note: To Learn more about the Flex2SQL Migration tool visit the Mertech Website at Flex2SQL - Migrate DataFlex to SQL.


There are two ways to create the view:

Using the Flex2SQL Migration tool

  1. Select the Flex2SQL shortcut from the Windows Start menu.
  2. In the Login dialog box Server Type field, select Oracle from the drop-down list.
  3. Select SYSDBA from the AutMode drop-down list.
  4. In the Server Name field, type the name of the server you are logging into.
  5. In the User Name field, type the SYSDBA user name (for example SYS or SYSTEM).
  6. In the Password field, type the user password.
  7. Click Connect to log into the server. Server-side license scripts run automatically.
  8. Logout, then login as a DEFAULT user before performing any migration work.


Executing the following SQL Script

create or replace view mds_session_info as select username, machine, terminal, module from v$session where module like 'ORAFlex%';
grant select on mds_session_info to public;
drop public synonym mds_session_info;
create public synonym mds_session_info for sys.mds_session_info;
commit;


For an Oracle Real Application Cluster (RAC), please contact Mertech Data for additional details.

Security Concerns

Questions have been asked about the requirement to create the MDS_SESSION_INFO view within the SYS schema. The purpose of MDS_SESSION_ INFO is to limit v$session information that is available to the application user to only ORAFlex connections ("where module like ORAFlex%").

Alternately, you can create the view in the user's schema, but you must then add "grant select on v_$session" to the script. Since v_$session is the underlying table of v$session view, this method opens up v$session to the user.

We recommend creating the view as the SYS user, since this provides the highest-level of security.