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.

Enabling ABL to <strong>SQL</strong> Correlation in Logging<br />

Connecting a schema holder<br />

The Enhanced Logger allows ABL to <strong>SQL</strong> correlation so that you can compare ABL<br />

database requests with <strong>SQL</strong> directives that are executed on the server.<br />

In the <strong>Data</strong><strong>Server</strong> log file, ABL to <strong>SQL</strong> correlation includes in<strong>for</strong>mation from the client<br />

context, the ABL module and line number, along with the server context <strong>SQL</strong> that was<br />

generated based on the ABL code and run against the <strong>for</strong>eign data source. The<br />

correlation is enabled using the -Dsrv PRGRS_LOG_ABL,n switch where n ranges from<br />

0 to 2, as demonstrated in the following example:<br />

-Dsrv logentrytypes,<strong>SQL</strong>:2,PRGRS_LOG_ABL,2<br />

For a <strong>Data</strong><strong>Server</strong> broker instance, the <strong>SQL</strong> log entry type can be set by using the -Dsrv<br />

logentrytypes,<strong>SQL</strong> switch in the ‘srvrStartupParam’ property under the<br />

UBroker.MS section in <strong>OpenEdge</strong> <strong>Management</strong>/<strong>OpenEdge</strong> Explorer or<br />

ubroker.properties files or using the parameter file .pf.<br />

Table 41 describes the PRGRS_LOG_ABL connect option values:<br />

Table 41: PRGRS_LOG_ABL connect option values<br />

Option Value Description<br />

0 Disables the ABL to <strong>SQL</strong> correlation feature. No correlation<br />

in<strong>for</strong>mation will be logged.<br />

1 Enables the ABL to <strong>SQL</strong> correlation feature <strong>for</strong> <strong>SQL</strong>-related log<br />

entry types. Every <strong>SQL</strong> request derived from the log entry type<br />

output is preceded by ABL filename and line number which can<br />

be correlated to a compiled listings file.<br />

2 Enables a superset of value 1 which, along with correlation<br />

in<strong>for</strong>mation, includes visual delimiters marking the start and<br />

end of each ABL file module.<br />

Note: The <strong>SQL</strong> log entry type is specifically designed to output <strong>SQL</strong>-related logging<br />

in<strong>for</strong>mation and there<strong>for</strong>e would be used most commonly in conjunction with<br />

the PRGRS_LOG_ABL -Dsrv switch. However, the PRGRS_LOG_ABL switch can<br />

be enabled to acquire module and line number in<strong>for</strong>mation with any log entry<br />

type that writes <strong>SQL</strong> request in<strong>for</strong>mation to the log.<br />

The ABL to <strong>SQL</strong> correlation is logged in the dataserv.lg file where the log entries will<br />

contain the ABL module and the line number where the ABL procedure started. It will<br />

also contain in<strong>for</strong>mation about the <strong>SQL</strong> query executed on the <strong>for</strong>eign data source and<br />

the visual delimiters.<br />

<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> 239

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

Saved successfully!

Ooh no, something went wrong!