Tutorial: Catalog a Connection

Before you can connect to the SQL Server database you created earlier, you must catalog it using the ADO.NET Connection Editor.

Requirements
Before attempting this tutorial, you must complete the following tutorials in the order listed:
  • Tutorial: Create a SQL Server Database
  • Tutorial: Create and Configure a Visual Studio Project
  • Tutorial: Set OpenESQL Assistant Configuration Options
Start the OpenESQL Assistant
You start the OpenESQL Assistant from Visual Studio.
  • In Visual Studio, click View > Micro Focus SQL Tools > OpenESQL Assistant.
Start the ADO.NET Connection Editor
You can start the ADO.NET Connection Editor from your Start menu or Start page, from the View menu in Visual Studio, or from within the OpenESQL Assistant (see To start the ADO.NET Connection Editor as a user for details). Here, you start it from within the OpenESQL Assistant.
  • In the OpenESQL Assistant, click Create New Query (ADO.NET Connection Editor).
Set to Save All Framework and Availability Combinations
By default, the platform target for your project is set to Any CPU. This means that it can use both 32- and 64-bit platforms and connections. In this tutorial, you catalog a 32-bit connection, but set the ADO.NET Connection editor to save all framework and connection combinations so that all are available regardless of the type of connection cataloged.
  • In the ADO.NET Connection editor, click Settings Menu icon > Save > All framework/availability combinations; then do one of the following:
    • If All framework/availability combinations is checked (Check mark), no further action is required.
    • If All framework/availability combinations is not checked, click it to check it.
Catalog the OESQLDemo Connection
Here you catalog a 32-bit connection to your SQL Server database.
  1. On the main window of the ADO.NET Connection Editor, click Add. This starts the Add an ADO.NET Connection wizard.
  2. Click Next.
  3. In the Data Source Name field, type OESQLDemo, which is the name of your connection; then click Next.
  4. In the .NET Data Providers grid, select SqlClient Data Provider; then click Next.
  5. Modify the following fields on the Connection Settings grid, providing the specified values:
    Field Value
    Data Source (local)
    Initial Catalog OESQLDemo
    Integrated Security True
  6. Click Next to review your settings.
  7. Click Finish to add the new connection. This returns you to the main window.
  8. After the Data Source Names list refreshes, select the OESQLDemo entry.
  9. Click Test to ensure the connection works properly; then click OK to clear the message.
Close the ADO.NET Connection Editor
  • To close the ADO.NET Connection Editor, click the close button in the upper right corner of the main window. This returns you to the OpenESQL Assistant.
Refresh the List of Connections in OpenESQL Assistant
To see the new connection in the OpenESQL Assistant, you must first refresh the list:
  • On the OpenESQL Assistant tool bar, click the Refresh list of data sources.