📄 toradb.html
字号:
<tr>
<a name="Close"></a>
<td>
<font class=fontcode>
procedure <b>Close</b>;
</font>
</td>
<td>
<font class=fontmain>
Closed connection with Oracle Server.
No exceptions are generated if connection is closed.
</font>
</td>
</tr>
<tr>
<a name=StartTransaction></a>
<td>
<font class=fontcode>
procedure <b>StartTransaction</b>;
</font>
</td>
<td>
<font class=fontmain>
Sets transaction isolation level (<a href=#OraTransIsolationLevel>OraTransIsolationLevel</a>)
and starts new transaction ( see also <a href=#InTransaction>InTransaction</a>)
</font>
</td>
</tr>
<tr>
<a name=CommitTransaction></a>
<td>
<font class=fontcode>
procedure <b>CommitTransaction</b>;
</font>
</td>
<td>
<font class=fontmain>
Commits the current transaction.
</font>
</td>
</tr>
<tr>
<td>
<font class=fontcode>
procedure <b>RollbackTransaction</b>;
</font>
</td>
<td>
<font class=fontmain>
Rollbacks the current transaction.
</font>
</td>
</tr>
<tr>
<td>
<font class=fontcode>
function <b>TestError</b>(where:string;ex:sword):sword;
</font>
</td>
<td>
<font class=fontmain>
Converts <b>OCI</b> error codes to the <b>Delphi</b> exceptions.
The first parameter is any string describing which of <b>OCI</b> calls has been
made, the second one is the <b>OCI</b> call return code.
</font>
</td>
</tr>
<tr>
<td>
<font class=fontcode>
procedure <b>GetServicesList</b>(AList: TStrings);
</font>
</td>
<td>
<font class=fontmain>
Parses file <b>tnsnames.ora</b> and returns a list of aliases (<b>AList: TStrings)</b> which
are presented on the current machine.
</font>
</td>
</tr>
<tr bgcolor="#009999">
<td colspan="2" align="center" valign="middle">
<font class=fontcaption>
Events
</font>
</td>
</tr>
<tr>
<td>
<font class=fontcode>
property <b>BeforeInitOCI</b>:TBeforeInitOCI;
</font>
</td>
<td>
<font class=fontmain>
<b>TBeforeInitOCI = procedure(Sender: TOraDB;LibName:string;Accept:boolean) of object;</b><br>
It is called before loading <b>oci.dll</b>, allows to change <b>oci.dll</b> path or
disable loading dll and initializing <b>OCI API</b>.
If initializing is not accepted in BeforeInitOCI event then
other events will not be called.
</font>
</td>
</tr>
<tr>
<td>
<font class=fontcode>
property <b>AfterInitOCI</b> :TAfterInitOCI;
</font>
</td>
<td>
<font class=fontmain>
<b>TAfterInitOCI = procedure(Sender: TOraDB) of object;</b><br>
It is called after the <b>OCI</b> library has been successfully initialized.
</font>
</td>
</tr>
<tr>
<td>
<font class=fontcode>
property <b>BeforeLogin</b>:TBeforeLoginEvent;
</font>
</td>
<td>
<font class=fontmain>
<b>TBeforeLoginEvent = procedure(Sender: TOraDB;var ConnectString,
Username, Password: string;Accept:boolean) of object;</b><br>
It will be called at the beginning of the <a href="#Open">Open</a>
method before the
first OCI function is called. To show a custom "logging on..." dialog,
use this event for triggering it. <br>
If <a href=#LoginPrompt>LoginPrompt</a>=<b>True</b> the
BeforeLogin event will be called before showing "Login Prompt" window.
</font>
</td>
</tr>
<tr>
<td>
<font class=fontcode>
property <b>AfterLogin</b>:TAfterLoginEvent ;
</font>
</td>
<td>
<font class=fontmain>
<b>TAfterLoginEvent = procedure(Sender: TOraDB) of object;</b><br>
It is called after the connection to the database has been established.
Allows to make some actions immediately after established connection.
For example, to execute sql statements to set special session parameters.
</font>
</td>
</tr>
<tr>
<td>
<font class=fontcode>
property <b>OnStartTransaction</b>:TNotifyEvent;
</font>
</td>
<td>
<font class=fontmain>
It is called after starting transaction before the end of
<a href=#StartTransaction>StartTransaction</a> method.
</font>
</td>
</tr>
<tr>
<td>
<font class=fontcode>
property <b>BeforeCommit</b>:TNotifyEvent;
</font>
</td>
<td>
<font class=fontmain>
it is called immediately before the <b>OCI</b> call <b>OCITransCommit</b>.
</font>
</td>
</tr>
<tr>
<td>
<font class=fontcode>
property <b>AfterCommit</b>:TNotifyEvent;
</font>
</td>
<td>
<font class=fontmain>
It is called after the current transaction has been committed. (at
the end of the
method <a href=#CommitTransaction>CommitTransaction</a>.
</font>
</td>
</tr>
</table>
<br>
<a name=TOraPreferences></a>
<h1 align=center>TOraPreferences</h1>
<br>
The property of this type is used to affect the behavior of other
database access components linked to the <a href="#TOraDB">TOraDB</a>.
<br><br>
<table cellspacing="0" cellpadding="5" border="1">
<tr bgcolor="#009999">
<td colspan="2" align="center" valign="middle">
<font class=fontcaption>
Properties
</font>
</td>
</tr>
<tr>
<td width=44%>
<font class=fontcode>
property <b>ConvertCRLF</b>:boolean;
</font>
</td>
<td>
<font class=fontmain>
Converts between <b>Windows</b> and <b>Unix</b> line breaks CRLF (#13#10) and LF (#10).<br>
If <b>ConvertCRLF</b> = <b>True</b> the SQL query text will be
converted to the Unix format before sending to the server.<br>
Otherwise no convertion has been made.
</font>
</td>
</tr>
<tr>
<td>
<font class=fontcode>
property <b>FloatPrecision</b>:integer;
</font>
</td>
<td>
<font class=fontmain>
Maximum precision to be represented a floating point field (<b>Double</b>).
Setting this property to <b>0</b> will cause all non-integer numbers to be represented as
a floating point field, even though a <b>Double</b> has a maximum precision of <b>15</b> digits.
Setting it to a non-zero value will cause higher-precision numbers to be represented as
a string field. The number will be converted to a string on the server, using the current
<b>NLS_LANG</b> settings. <br>
This preference affects fields in <b>TAOraSQL</b> and <b>TOraSQL</b> components.
</font>
</td>
</tr>
<tr>
<td>
<font class=fontcode>
property <b>IntegerPrecision</b>:integer;
</font>
</td>
<td>
<font class=fontmain>
Maximum precision to be represented an <b>Integer</b> field. Setting
this property to <b>0</b> will cause all <b>Integer</b> numbers with a
precision of <b>9</b> digits or less to be represented as an integer,
and all other numbers as a floating point value, depending on the
<b>FloatPrecision</b> preference.<br>
This preference affects fields in <b>TAOraSQL</b> and <b>TOraSQL</b> components.
</font>
</td>
</tr>
<tr>
<td>
<font class=fontcode>
property <b>SmallIntPrecision</b>:integer;
</font>
</td>
<td>
<font class=fontmain>
Maximum precision to be represented as a small integer field (<b>SmallInt</b>).
Setting this property to <b>0</b> will cause all integer numbers with a precision
of <b>4</b> digits or less to be represented as a small integer. This preference
only affects fields in the <b>TAOraSQL</b> and <b>TOraSQL</b> component.
???The default value of this property is <b>-1</b>, so that small integer
fields will never occur.???
</font>
</td>
</tr>
</table>
<br>
<br>
</font>
<div align=right>
<font class=fontsmall>
Copyright (c) by Andrey Romanchenko
</font>
</div>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -