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

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Tuning your environment with the –Dsrv startup parameter<br />

<strong>SQL</strong> statements cache—the PRGRS_PREPCACHE option<br />

The <strong>Data</strong><strong>Server</strong> keeps a cache of prepared <strong>SQL</strong> statements that it reuses with new parameters.<br />

This mechanism improves the <strong>Data</strong><strong>Server</strong> per<strong>for</strong>mance. You can use the PRGRS_PREPCACHE<br />

option to manage this cache in two ways:<br />

• The MS <strong>SQL</strong> <strong>Server</strong> drivers are capable of re-using prepared statements and should do so<br />

whenever possible. However, using -Dsrv PRGRS_PREPCACHE,0 instructs the <strong>Data</strong><strong>Server</strong><br />

to re-prepare each <strong>SQL</strong> statement.<br />

• Use the PRGRS_PREPCACHE option to control the size of the cache. The default cache size is<br />

20 statements. You can increase the size <strong>for</strong> large applications that reuse many queries.<br />

The maximum size depends on the amount of resources you have available.<br />

Concurrent procedure results—the PRGRS_PROC_TRAN option<br />

The <strong>Data</strong><strong>Server</strong> allows only one active request <strong>for</strong> running a stored procedure. However, you<br />

can process results <strong>for</strong>m several stored procedures concurrently if you set the PRGRS_PROC_TRAN<br />

switch to 1 (ON.) When switched on, this option will cause a separate connection to be used <strong>for</strong><br />

each stored procedure request, up to the maximum number of connections specified by the<br />

PRGRS_CACHE_CONN option.<br />

Caution: When procedures run in separate connections of the same <strong>Data</strong><strong>Server</strong> session, the<br />

scope of their respective transactions is isolated from one another. If one active<br />

procedure attempts to update the same record used by another active procedure in the<br />

same session, a lock timeout or even a deadlock could occur.<br />

Cursor characteristics—the PRGRS_STABLE_CURS option<br />

Enabling this switch indicates to the <strong>Data</strong><strong>Server</strong> that it should assume that all cursors are stable.<br />

Normally, the ODBC driver and MS <strong>SQL</strong> <strong>Server</strong> determines whether a cursor is stable during<br />

the commit or rollback of a transaction and if the cursor can persist beyond a single transaction<br />

scope. The <strong>Data</strong><strong>Server</strong> normally resolves cursor characteristics by interrogating the driver and<br />

setting the run-time environment accordingly.<br />

Progress Software Corporation does not recommend bypassing normal operation under most<br />

circumstances, but under very limited circumstances, you can improve per<strong>for</strong>mance by<br />

overriding the derived cursor setting by setting the PRGRS_STABLE_CURS option to 1 (ON). Your<br />

application must comply to one of the following restrictions to safely enable this option:<br />

• All ABL run in your <strong>Data</strong><strong>Server</strong> session is without transactions.<br />

• ABL run in your <strong>Data</strong><strong>Server</strong> session has transactions, but all ABL queries and resultant<br />

data sets are fully processed on one side of any existing transaction boundary.<br />

Note: This is a session-level switch, which means that all ABL run in the session must<br />

comply with the listed restrictions.<br />

8–9

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

Saved successfully!

Ooh no, something went wrong!