13.01.2013 Views

OpenEdge Data Management: DataServer for Microsoft SQL Server

OpenEdge Data Management: DataServer for Microsoft SQL Server

OpenEdge Data Management: DataServer for Microsoft SQL Server

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Chapter 6: Connecting the <strong>Data</strong><strong>Server</strong><br />

Connecting a schema holder<br />

As described previously, connection can take place automatically using the in<strong>for</strong>mation<br />

that you enter when you create a schema holder. In addition, <strong>OpenEdge</strong> provides the<br />

following techniques <strong>for</strong> connecting to a schema holder:<br />

• Use the <strong>Data</strong> Dictionary or <strong>Data</strong> Administration. From the main menu, select<br />

<strong>Data</strong>base→ Connect and supply the schema holder’s physical name and the<br />

appropriate connection parameters. You can then select your MS <strong>SQL</strong> <strong>Server</strong><br />

database as your working database and connect to it. You cannot use the<br />

Utilities→ Edit <strong>OpenEdge</strong> Auto–Connect option to connect to a MS <strong>SQL</strong> <strong>Server</strong><br />

data source.<br />

• Use the ABL CONNECT statement (see its reference entry in <strong>OpenEdge</strong><br />

Development: ABL Reference). A CONNECT statement must first list the schema<br />

holder and related connection parameters, then the MS <strong>SQL</strong> <strong>Server</strong> database and<br />

related parameters.<br />

This command connects a schema holder named mssholder and MS <strong>SQL</strong> <strong>Server</strong><br />

database named mssdemo:<br />

CONNECT mssholder -1 -db mssdemo -dt MSS<br />

-Dsrv qt_debug,EXTENDED<br />

• Use connection parameters when you start <strong>OpenEdge</strong>. You can include these<br />

parameters on the program item command line or in a parameter file that you<br />

specify when you start <strong>OpenEdge</strong>. A parameter file is portable and easy to<br />

maintain. For in<strong>for</strong>mation on creating a parameter file, see <strong>OpenEdge</strong><br />

Deployment: Startup Command and Parameter Reference.<br />

You can use combinations of different connection techniques. For example, you can<br />

connect the schema holder at startup, then connect to the <strong>Data</strong><strong>Server</strong> using the<br />

<strong>OpenEdge</strong> CONNECT statement. If the proper connect in<strong>for</strong>mation is stored in the<br />

schema holder, referencing a table in the MS <strong>SQL</strong> <strong>Server</strong> database will cause the<br />

<strong>Data</strong><strong>Server</strong> to issue the connect statement automatically. Any combination of<br />

connection techniques works, as long as you first connect to the schema holder and<br />

then the MS <strong>SQL</strong> <strong>Server</strong> data source.<br />

If you are not updating the schema holder, you can specify the Read-only (-RO)<br />

connection parameter to enhance <strong>Data</strong><strong>Server</strong> per<strong>for</strong>mance.<br />

If you connect to the schema holder and the MS <strong>SQL</strong> <strong>Server</strong> database in a single<br />

startup command or connection statement, be sure to specify parameters that affect<br />

the schema holder be<strong>for</strong>e the <strong>Data</strong>base Name (-db) parameter. Specify only those<br />

parameters that affect the MS <strong>SQL</strong> <strong>Server</strong> database connection after the -db<br />

parameter.<br />

The following section explains how to connect both a schema holder and a MS <strong>SQL</strong><br />

<strong>Server</strong> database when you start up <strong>OpenEdge</strong>.<br />

218 <strong>OpenEdge</strong> <strong>Data</strong> <strong>Management</strong>: <strong>Data</strong><strong>Server</strong> <strong>for</strong> <strong>Microsoft</strong> <strong>SQL</strong> <strong>Server</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!