⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 toradb.html

📁 delphi通过OCI访问ORACLE
💻 HTML
📖 第 1 页 / 共 2 页
字号:
<html>
<head>
<link rel="stylesheet" type="text/css" href="style.css">
<title>TOraDB</title>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1251">
</head>

<body bgcolor="#FFFFFF" text="#000000">


<table width="100%" border="0" cellpadding="5" cellspacing="0">
   <tr>
   <td align=center bgColor=#009999>
    <font class=fontmainbig color="#FFFFFF">
     <b>DOCI Components for Direct Oracle Access <br></b>
	</font>
	<br>
    <font class=fontmain color="#FFFFFF"> 
     <b>Version 1.19</b><br>
    </font>
	
   </td>
   </tr>
</table>

<font class=fontmain>

<p>Copyright &copy; 1998-2003 by Andrey Romanchenko<br>
All rights reserved.

<p>

<table cellspacing=2 cellpadding=0>
<tr>
   <td><font class=fontmain>
    <i>e-mail:&nbsp;&nbsp;</i></font>
	</td>
	<td><font class=fontmain>
	 <a href="mailto:lasersquard@tut.by?subject=DOCI">lasersquad@tut.by</a></font>
	</td>
</tr>
<tr>
   <td><font class=fontmain>
    <i>web site:&nbsp;&nbsp;</i></font>
   </td>
   <td><font class=fontmain>
    <a href="http://www.suptas.com" target=_new>http://www.suptas.com/</a><br>
    <a href="http://sourceforge.net/projects/delphioci/" target=_new>http://sourceforge.net/projects/delphioci/</a></font>
	</td>
</tr>
</table>

<br><br>

<a name="TOraDB"></a>
<h1 align=center>TOraDB</h1>
The core component of DOCI library. <br>
Establishes Oracle server connection, manages transactions. 
<br>
 Other components (such as TAOraSQL and TOraSQL) use this component to connect to the 
 database. All OCI calls are concentrated inside this component.

<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>
<a name=Active></a>
	<td> <font class=fontcode>
      property <b>Active</b>:boolean;
	  	</font>
	</td>
	<td><font class=fontmain >
             Set this property to true is the same as to call method <a href="#Open">Open</a>.<br>
             Set this property to false is the same as to call method 
             <a href="#Close">Close</a>.
		</font> 
	</td>
</tr>

<tr>
<a name=DBLogin></a>
	<td> <font class=fontcode>
      property <b>DBLogin</b>:string;
	  	</font>
	</td>
	<td><font class=fontmain >
             Username to login to the database.
		</font> 
	</td>
</tr>
<tr>
<a name=DBPassword></a>
	<td> <font class=fontcode>
      property <b>DBPassword</b>:string;
	  	</font>
	</td>
	<td><font class=fontmain >
              Password for login.  
			  </font> 
	</td>
</tr>
<tr>
<a name=DBServer></a>
	<td> <font class=fontcode>
      property <b>DBServer</b>:string;
	  	</font>
	</td>
	<td><font class=fontmain >
             Server alias.<br>
			 Server alias can be created with "<b>Oracle Net8 Easy 
Config</b>" program or just by 
             editing %oraclehome%/network/admin/tnsnames.ora file
             (%oraclehome%/net80/admin/tnsnames.ora - for several versions of <b>Oracle Client</b>).
		</font> 
	</td>
</tr>
<tr>
	<td> <font class=fontcode>
      property <b>ConnectAs</b>:TOraConnectAs;
	  	</font>
	</td>
	<td><font class=fontmain >
			<b>TOraConnectAs   = (caNormal, caSYSDBA, caSYSOPER);</b><br>
			Indicates whether the user should be logged in with 
<b>SYSDBA</b>, <b>SYSOPER</b> or with
            a normally privileged connection. The <b>caSYSDBA</b> and <b>caSYSOPER</b> options are only possible 
			if you have been granted the corresponding system privilege and if you know 
			the corresponding password.<br>

			<b>SYSOPER<	/b> - permits you to perform alter database open/mount, alter database backup, 
			archive log, and recover, and includes the restricted session privilege.<br>

			<b>SYSDBA</b> - contains all system privileges with admin option and the sysoper system 
			privilege; permits to create database and time-based recovery.<br>

			In both situations the default schema is now SYS instead of the schema of the 
			username of the session.<br>

			<b>NOTE!</b> This property will only work on <b>Net8</b>.

		</font> 
	</td>
</tr>
<tr>
<a name=LoginPrompt></a>
	<td> <font class=fontcode>
      property <b>LoginPrompt</b>:boolean;
	  	</font>
	</td>
	<td><font class=fontmain >
            Whether to show a login dialog window or not.<br>
			<b>True</b> - to show.<br>
			<b>False</b>- do NOT show. <br>
            
 		</font> 
	</td>
</tr>
<tr>
<a name=OraSessionIsolationLevel></a>
	<td> <font class=fontcode>
      property <b>OraSessionIsolationLevel</b>:TOraSessionIsolationLevel;
	  	</font>
	</td>
	<td><font class=fontmain >
          Transaction isolation level for session (connection).
          All new transactions in this session by default will have the specified 
          isolation level (unless it is overriden by <b>OraTransIsolationLevel</b>).
		</font> 
	</td>
</tr>
<tr>
<a name=OraTransIsolationLevel></a>
	<td> <font class=fontcode>
      property <b>OraTransIsolationLevel</b>:TOraTransIsolationLevel;
	  	</font>
	</td>
	<td><font class=fontmain >
           Isolation level for new transactions inside current session (connection). 
		   Each new transaction will have the specified isolation level.
 
		   If <b>OraTransIsolationLevel = tiDefault</b> then each new transaction gets its
           isolation level from <b>OraSessionIsolationLevel</b> property.
		</font> 
	</td>
</tr>
<tr>
	<td> <font class=fontcode>
      property <b>Preferences</b>:TOraPreferences;
	  	</font>
	</td>
	<td><font class=fontmain >
              The <b>Preferences</b> property can be used to affect the behavior 
of other database access components linked to the <b>TOraDB</b>. The following 
properties can be defined as (detail description <a href='#TOraPreferences'> here</a>):<br>
			 <ul>
			   <li> <b>ConvertCRLF:boolean;</b>
			   <li> <b>FloatPrecision:integer;</b>
               <li> <b>IntegerPrecision:integer;</b>
               <li> <b>SmallIntPrecision:integer;</b>
            </ul>
		</font> 
	</td>
</tr>
<tr>
	<td> <font class=fontcode>
      property <b>RollbackOnDisconnect</b>:boolean;
	  	</font>
	</td>
	<td><font class=fontmain >
			This property indicates that the session should rollback the current 
			transaction or not when it is disconnected. If an application crashes without freeing 
            its TOraDB components, the Oracle Server will always rollback the current transaction.
		</font> 
	</td>
</tr>
<tr>
	<td> <font class=fontcode>
      property <b>SQLTrace</b>:TOraSQLTrace;
	  	</font>
	</td>
	<td><font class=fontmain >
			This property can enable or disable the SQL trace option for the session. 
            When it is set to stTrue, it is possible to analyze all executed SQL statements with Oracle's tkprof utility. 
            It gives information about CPU time, elapsed time, disk I/O, etc of each statement. 
            See the "Oracle Server Tuning" manual for detailed information about tkprof.
 			When SQLTrace is set to stDefault, the initialization parameter SQL_TRACE of 
            the Oracle instance determines if SQL trace is enabled or disabled.
		</font> 
	</td>                          	
</tr>
<tr>
<a name=InTransaction></a>
	<td> <font class=fontcode>
      property  <b>InTransaction</b>:boolean;readonly!
	  	</font>
	</td>
	<td><font class=fontmain >
            Indicates whether the session has started a transactionor not. 
            This property is read only.
		</font> 
	</td>
</tr>

<tr bgcolor="#009999">
	<td colspan="2" align="center" valign="middle">
	 <font class=fontcaption>
	  Public Methods
	 </font> 
	</td>

</tr>
<tr>
	<td>
	 <font class=fontcode>
	  constructor <b>Create</b>(AOwner:TComponent); override;
	 </font> 
	</td>
	<td>
	 <font class=fontmain>
       Constructor of <b>TOraDB</b> component.    
	 </font> 
	</td>
</tr>
<tr>
	<td>
	 <font class=fontcode>
	  destructor <b>Destroy</b>; override;
	 </font> 
	</td>
	<td>
	 <font class=fontmain>
         Closes session (if needed) and destroys the component.
	 </font> 
	</td>
</tr>
<tr>
<a name="Open"></a>
	<td>
	 <font class=fontcode>
	  procedure <b>Open</b>;
	 </font> 
	</td>
	<td>
	 <font class=fontmain>
 	 	 Connects to the database and opens session. 
 		 ??If the session is already logged on, it is first logged off.??
						
		 If LoginPrompt is True then login dialog box appeares on the screen to ask 
		 username and password, otherwise properties <a href=#DBLogin>DBLogin</a>, 
		 <a href=#DBPassword>DBPassword</a> and <a href=#DBServer> DBServer</a> are used.
		 If an error occurs, an EDatabaseError exception is raised (!can be changed in future!).
		     
	 </font>
	</td>
</tr>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -