Easysoft Blog

Fri, 15 May 2020

Connect APPX to SQL Server

APPX is a Rapid Application Development (RAD) and runtime environment that enables its users to create cross-platform, database-independent applications. APPX supports ODBC, which means an APPX application can work with data from any database for which an ODBC driver is available.

The blog shows how to use Easysoft's SQL Server ODBC driver to work with SQL Server data from APPX on Windows.

Connectivity Requirements

Installing the SQL Server ODBC Driver

  1. Download the SQL Server ODBC driver for your Windows platform. (Registration required.)
  2. Install and license the SQL Server ODBC driver on the machine where APPX is installed.

    The install program starts the Easysoft License Manager, because you cannot use the SQL Server ODBC Driver until a license is obtained.

    The following types of license are available:

    • Free time-limited trial license which gives you free and unrestricted use of the product for a limited period (usually 14 days).
    • Full license if you have purchased the product. On purchasing the product you are given an authorization code, which you use to obtain a license
  3. In Easysoft License Manager, enter your details.

    You MUST enter the Name, E-Mail Address and Company fields.

    The E-Mail Address MUST be the same as the address used to register and download from the Easysoft web site or you will be unable to obtain trial licenses.

  4. Choose Request License.

    You are asked for a license type.

  5. Do one of the following:
    • For a trial license click Time Limited Trial and then click Next.

      The License Manager asks what software you are licensing. Select Easysoft SQL Server ODBC Driver from the drop-down list and then click Next.

    • If you have obtained an authorization code for a purchased license, select Non-expiring License and then click Next.

      The License Manager requests your authorization code.

      Enter the authorization code and then click Next.

  6. The License Manager displays a summary of the information you entered and allows you to choose the method of applying for your license.
  7. Do one of the following:
    • Choose On-line Request if your machine is connected to the internet and can make outgoing connections to port 8884.

      The License Manager then sends a request to the Easysoft license server to activate your license key automatically. This is the quickest method and results in your details being entered immediately into our support database.

    • The remaining three options (Email Request, Print Request and View Request) are all ways to obtain a license if your machine is off-line (i.e. does not have a connection to the internet).

      Each of these methods involves providing Easysoft with information including your machine number (a number unique to your machine) and then waiting to receive your license key.

      Instead of emailing your details to Easysoft, you can enter them directly at the Easysoft web site and your license key will be emailed to you automatically.

      To use this method, click View Request, and then visit:

      In the Licensing page, enter your machine number (and authorization code for purchased license), click Submit and your license key will be emailed to you.

      When you receive the license key, you can activate it either by double-clicking the email attachment or by clicking Enter License on the License Manager main screen and pasting the license key into the dialog box.

    • Choose Finish to exit the License Manager.

      The installation is complete.

Configuring an ODBC Data Source

Before you can use the SQL Server ODBC Driver to connect APPX to SQL Server, you need to configure an ODBC data source. An ODBC data source stores the connection details for the target database (e.g. SQL Server) and the ODBC driver that is required to connect to it (e.g. the SQL Server ODBC driver).

You configure ODBC data sources in ODBC Administrator, which is included with Windows. How you run ODBC Administrator depends on whether your version of APPX is 32-bit or 64-bit.

If your version of APPX is 64-bit, you need to use the 64-bit version of ODBC Administrator. In the Windows Run dialog box, enter:

odbcad32.exe

If your version of APPX is 32-bit, you need to use the 32-bit version of ODBC Administrator. In the Windows Run dialog box, enter:

%windir%\syswow64\odbcad32.exe

In ODBC Administrator:

  1. Choose the System DSN tab
  2. Choose the Add button
  3. Choose Easysoft ODBC-SQL Server Driver from the list of drivers, and then choose OK.
  4. Complete these fields in the Easysoft ODBC-SQL Server Driver DSN Setup dialog box:
    Field Value
    DSN MSSQL
    Database The database that contains the data you want to work with in APPX
    Server myserver\myinstance
  5. Choose the Authentication tab.
  6. If you want to connect to SQL Server by using you Windows user name, choose With Integrated Windows authentication. Otherwise, choose With SQL Server authentication using a login ID and password, and enter your SQL Server login details in the spaces provided. E.g., "sa" and "mypassword".

APPX

If you have not already done so, install and start the APPX/ODBC Server on the Windows machine where your APPX server is running.

  1. Use the APPX desktop client to connect to your APPX server.

    The APPX server interface is displayed

    Set up an FMS group to tell APPX how to connect to SQL Server. The FMS group tells APPX which ODBC data source to use and what table naming convention to use.

  2. Choose System Administration > File Management > FMS Groups.
  3. Choose the Add button.
  4. Name the FMS group "sqlserver".
  5. Specify the FMS type as "6".
  6. Choose the Tick button

    The FMS Group Options (ODBC) dialog box is displayed.

  7. Choose the Magnifying Glass button. Choose the Easysoft SQL Server ODBC driver data source frokm the list.
  8. Choose the Hints button.
  9. Choose the $db_$appl_$file format.
  10. Choose System Administration > Runtime Configuration > Database Definitions.
  11. Choose the application you want to work with SQL Server data in from the list. Choose the Tick button twice to display the Related Applications dialog box.
  12. Choose the application you want to work with SQL Server data in from the list and then choose the Database Management button.
  13. Choose File Specifications.
  14. In the file you want to populate with SQL Server data, set FMS to 6. Set FMS Group to the newly created group.


Oracle is a registered trademark of Oracle Corporation and/or its affiliates.