Copies an alias table to another alias table.
Syntax
EsbOtlCopyAliasTable (hOutline, pszSourceAliasTable, pszDestAliasTable, fMerge) ByVal hOutline As Long ByVal pszSourceAliasTable As String ByVal pszDestAliasTable As String ByVal fMerge As Integer
Parameter | Description |
---|---|
hOutline | Outline context handle. |
pszSourceAliasTable | Name of alias table to copy from. If this parameter is "", the default alias table is used. |
pszDestAliasTable | Name of alias table to copy to. |
fMerge | Set to ESB_YES to merge the source file into the existing destination alias table. Set to ESB_NO to clear the destination alias table before copying. |
Notes
If the destination alias table does not exist, it is created. If the destination alias table exists, it is cleared first, unless the fMerge flag is set to ESB_YES.
The maximum number of alias tables in a single block storage or aggregate storage database outline (including the default table) is 32.
When copying an alias table, language codes associated with the alias table are removed from the copied alias table.
Return Value
Returns 0 if successful; otherwise one of the following:
OTLAPI_BAD_ALIASTABLE
OTLAPI_ERR_MAXALIASTABLES
OTLAPI_ERR_ALIASTABLENAME
Example
Declare Function EsbOtlCopyAliasTable Lib "ESBOTLN" (ByVal hOutline As Long, ByVal pszSourceAliasTable As String, ByVal pszDestAliasTable As String, ByVal fMerge As Integer) As Long Sub ESB_OtlCopyAliasTable() Dim sts As Long Dim Object As ESB_OBJDEF_T Dim hOutline As Long Object.hCtx = hCtx Object.Type = ESB_OBJTYPE_OUTLINE Object.AppName = "Sample" Object.DbName = "Basic" Object.FileName = "Basic" sts = EsbOtlOpenOutline(hCtx, Object, ESB_YES, ESB_YES, hOutline) If sts = 0 Then sts = EsbOtlCopyAliasTable (hOutline, "", "Alias Table 2", ESB_YES) End If End Sub
See Also