ttCacheSqlGet
This procedure generates the Oracle SQL statements to install or uninstall Oracle database objects.
This procedure generates statements for:
-
Read-only cache groups
-
User managed cache groups with incremental autorefresh
-
Asynchronous writethrough (AWT) cache groups
This is useful when the user creating the cache group does not have adequate privilege to write on the Oracle database. The Oracle DBA can then use the script generated by this built-in procedure to create the Oracle database objects.
Required Privilege
This procedure requires the CACHE_MANAGER
privilege.
Usage in TimesTen Scaleout and TimesTen Classic
This procedure is supported in both TimesTen Classic and TimesTen Scaleout.Related Views
This procedure has no related views.
Syntax
ttCacheSqlGet('feature_name', 'cache_group_name', install_flag)
Parameters
ttCacheSqlGet
has these parameters:
Parameter | Type | Description |
---|---|---|
|
|
Can be specified as |
|
|
The name of the cache group. Specify |
|
|
If If |
Result Set
ttCacheSqlGet
returns the result set:
Column | Type | Description |
---|---|---|
|
|
The Oracle SQL statement to uninstall or install autorefresh or asynchronous writethrough Oracle database objects. |
|
|
nonzero only if the Oracle SQL statement in the |
Examples
CALL ttCacheSqlGet('INCREMENTAL_AUTOREFRESH', 'westernCustomers', 1);
To remove all Oracle database objects in the autorefresh user's account, use:
CALL ttCacheSqlGet('INCREMENTAL_AUTOREFRESH', NULL, 0);
Notes
-
This procedure is available only for cache operations.
-
Each returned
retval
field contains a separate Oracle SQL statement that may be directly executed on the Oracle database. A row may end in the middle of a statement, as indicated by thecontinueFlag
field. In this case, the statement must be concatenated with the previous row to produce a usable SQL statement. -
The script output of this procedure is not compatible with Oracle's SQL*Plus utility. However, you can use the
ttIsql
cachesqlget
command to generate a script that is compatible with the SQL*Plus utility. -
You can specify
NULL
for thecache_group_name
option to generate Oracle SQL to clean up Oracle database objects after a database has been destroyed by thettDestroy
utility.