copyingtables.htm

来自「Absolute Database 5.12 src. Absolute Da」· HTM 代码 · 共 74 行

HTM
74
字号
<html>
<head>
   <title>Copying Tables</title>
</head>

<!--#include virtual="/inc/header.php"-->


<table width="100%" border="0" cellspacing="0" cellpadding="2" bgcolor="#FFFFFF">
  <tr>
    <td align="left">
      
<span style="font-family:Helvetica,Arial; font-size:12pt; color:#000000"><b>Copying Tables
<br>
</b></span>
    </td>
    <td align="right">
     <font face="Arial" size="2">
     <a href="emptyingtables.htm">Previous</a>&nbsp;
     <a href="overview.htm">Top</a>&nbsp;
     <a href="accessingblobfields.htm">Next</a>
     </font>
    </td>
  </tr>
</table>
<br><br>



<span style="font-family:Helvetica,Arial; font-size:10pt; color:#000000">
<br>
To copy a table, specify the <a href=tabsdataset_databasename.htm>DatabaseName</a> and <a href=tabstable_tablename.htm>TableName</a> properties of the TABSTable component and then call the <a href=tabstable_copytable.htm>CopyTable</a> method.  
<br>

<br>
If you would like to copy table to the same database file, you should not pass second parameter to the <i>CopyTable</i> call.
<br>

<br>
<b>Example:
<br>

<br>
</b><span style="font-family:Courier New; font-size:8pt; color:#000000">&nbsp;&nbsp;ABSTable1.DatabaseName&nbsp;:=&nbsp;<span style="font-family:Courier New; font-size:8pt; color:#000080">'emp_db'</span></span><span style="font-family:Courier New; font-size:8pt; color:#000000">;
<br>
&nbsp;&nbsp;ABSTable1.TableName&nbsp;:=&nbsp;<span style="font-family:Courier New; font-size:8pt; color:#000080">'employee'</span></span><span style="font-family:Courier New; font-size:8pt; color:#000000">;
<br>
&nbsp;&nbsp;ABSTable1.CopyTable(<span style="font-family:Courier New; font-size:8pt; color:#000080">'new_employee'</span></span><span style="font-family:Courier New; font-size:8pt; color:#000000">);
<br>

<br>

<br>
</span><span style="font-family:Helvetica,Arial; font-size:10pt; color:#000000">If you would like to copy table to the another database file, you should pass destination database file name as as second parameter to the <i>CopyTable</i> call.
<br>

<br>
<b>Example:
<br>

<br>
</b></span><span style="font-family:Courier New; font-size:8pt; color:#000000">&nbsp;&nbsp;ABSTable1.DatabaseName&nbsp;:=&nbsp;<span style="font-family:Courier New; font-size:8pt; color:#000080">'emp_db'</span></span><span style="font-family:Courier New; font-size:8pt; color:#000000">;
<br>
&nbsp;&nbsp;ABSTable1.TableName&nbsp;:=&nbsp;<span style="font-family:Courier New; font-size:8pt; color:#000080">'employee'</span></span><span style="font-family:Courier New; font-size:8pt; color:#000000">;
<br>
&nbsp;&nbsp;ABSTable1.CopyTable(<span style="font-family:Courier New; font-size:8pt; color:#000080">'new_employee',&nbsp;'c:\data\emp_db2.abs'</span></span><span style="font-family:Courier New; font-size:8pt; color:#000000">);
<br>

<br>
</span></span>

<!--#include virtual="/inc/footer.php"--> 
</html>

⌨️ 快捷键说明

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