Connect to Sage US Data in Aqua Data Studio

Access Sage US data from tools in Aqua Data Studio such as the Visual Query Builder and the Table Data Editor.

The CData JDBC Driver for Sage US integrates Sage US data with wizards and analytics in IDEs like Aqua Data Studio. This article shows how to connect to Sage US data through the connection manager and execute queries.

Create a JDBC Data Source

You can use the connection manager to define connection properties and save them in a new JDBC data source. The Sage US data source can then be accessed from Aqua Data Studio tools.

  1. In Aqua Data Studio, select Register Server from the Servers menu.
  2. In the Register Server form, select the 'Generic - JDBC' connection.
  3. Enter the following JDBC connection properties:
    • Name: Enter a name for the data source; for example, Sage US.
    • Driver Location: Click the Browse button and select the cdata.jdbc.sage50us.jar file, located in the lib subfolder of the installation directory.
    • Driver: Enter the Driver's class name, cdata.jdbc.sage50us.Sage50USDriver.
    • URL: Enter the JDBC URL, which starts with jdbc:sage50us: and is followed by a semicolon-separated list of connection properties. You will find information on the required connection string options in the help documentation. A typical JDBC URL is below:

      jdbc:sage50us:ApplicationId=8dfafu4V4ODmh1fM0xx;CompanyName=Bellwether Garden Supply - Premium;
  4. The Application Id and Company Name connection string options are required to connect to Sage as a data source. You can obtain an Application Id by contacting Sage directly to request access to the Sage 50 SDK.

    Sage must be installed on the machine. The Sage.Peachtree.API.dll and Sage.Peachtree.API.Resolver.dll assemblies are required. These assemblies are installed with Sage in C:\Program Files\Sage\Peachtree\API\. Additionally, the Sage SDK requires .NET Framework 4.0 and is only compatible with 32-bit applications. To use the Sage SDK in Visual Studio, set the Platform Target property to "x86" in Project -> Properties -> Build.

    You must authorize the application to access company data: To authorize your application to access Sage, restart the Sage application, open the company you want to access, and connect with your application. You will then be prompted to set access permissions for the application in the resulting dialog.

    While the compiled executable will require authorization only once, during development you may need to follow this process to reauthorize a new build. To avoid restarting the Sage application when developing with Visual Studio, click Build -> Configuration Manager and uncheck "Build" for your project.

Query Sage US Data

You can now query the tables exposed.

 
 
ダウンロード