Note
- This view is available starting with V4.3.1 in V4.3.x.
- This view is available starting with V4.2.2 in V4.2.x.
Purpose
This view displays the basic information about PL-related cache objects in all servers of all tenants.
Columns
| Column | Type | Nullable | Description |
|---|---|---|---|
| TENANT_ID | bigint(20) | NO | Tenant ID:
|
| SVR_IP | varchar(46) | NO | IP address of the node where the cache object is located |
| SVR_PORT | bigint(20) | NO | Port number of the node where the cache object is located |
| CACHE_OBJECT_ID | bigint(20) | NO | ID of the cache object allocated by lib cache |
| PARAMETERIZE_TEXT | longtext | NO |
|
| OBJECT_TEXT | longtext | NO | Text of the query statement. This column is valid only for anonymous blocks and CALL statements in PS mode. |
| FIRST_LOAD_TIME | timestamp(6) | NO | Time when the cache object was first loaded, in microseconds |
| LAST_ACTIVE_TIME | timestamp(6) | NO | Time of the last cache hit, in microseconds |
| AVG_EXE_USEC | bigint(20) | NO | Average execution time, in microseconds |
| SLOWEST_EXE_TIME | timestamp(6) | NO | Timestamp of the slowest execution, in microseconds |
| SLOWEST_EXE_USEC | bigint(20) | NO | Slowest execution time, in microseconds |
| HIT_COUNT | bigint(20) | NO | Number of cache hits |
| CACHE_OBJ_SIZE | bigint(20) | NO | Size of the memory occupied by the cache object |
| EXECUTIONS | bigint(20) | NO | Number of successful executions of the stored procedure |
| ELAPSED_TIME | bigint(20) unsigned | NO | Time of the last execution of the stored procedure, in microseconds |
| OBJECT_TYPE | longtext | NO | Type of the cache object (such as Procedure, Function, and Trigger) |
| OBJECT_ID | bigint(20) unsigned | NO | ID of the stored procedure object (routine_id/package_id) |
| COMPILE_TIME | bigint(20) unsigned | NO | Time spent on the compilation of the stored procedure, in microseconds |
| SCHEMA_VERSION | bigint(20) | NO | Schema version number |
| PS_STMT_ID | bigint(20) | NO | Prepare ID corresponding to the request:
|
| DB_ID | bigint(20) unsigned | NO | ID of the database used for the compilation of the stored procedure
Note |
| PL_CG_MEM_HOLD | bigint(20) | NO | Memory held during the PL CG stage
Note |
| SYS_VARS | varchar(4096) | NO | System variables that affect plan generation in the current session
Note |
| PARAM_INFOS | longtext | NO | Information about the parameterized types for anonymous blocks and call proc info
Note |
| SQL_ID | varchar(32) | NO | Unique ID generated by using the MD5 value of db_name+routine_name
Note |
| OUTLINE_VERSION | bigint(20) | NO | Version of the throttling outline. The default value is 0
Note |
| OUTLINE_ID | bigint(20) | NO | ID of the throttling outline. The default value is -1
Note |
| CONCURRENT_DATA | longtext | NO | The throttling content, which defaults to /*+max_concurrent(-1)*/. -1 indicates that no throttling is performed.
Note |
Sample query
Query the basic information of all PL-related cache objects in all servers of all tenants.
obclient > SELECT * FROM oceanbase.GV$OB_PL_CACHE_OBJECT limit 1 \G
The query result is as follows:
*************************** 1. row ***************************
TENANT_ID: 1
SVR_IP: 172.xx.xx.xx
SVR_PORT: 2882
CACHE_OBJECT_ID: 1889
PARAMETERIZE_TEXT: oceanbase.dbms_stats
OBJECT_TEXT: NULL
FIRST_LOAD_TIME: 2025-07-30 16:43:01.654706
LAST_ACTIVE_TIME: 2025-08-04 16:43:01.631334
AVG_EXE_USEC: 0
SLOWEST_EXE_TIME: 1970-01-01 08:00:00.000000
SLOWEST_EXE_USEC: 0
HIT_COUNT: 490
CACHE_OBJ_SIZE: 23808
EXECUTIONS: 0
ELAPSED_TIME: 0
OBJECT_TYPE: PACKAGE
OBJECT_ID: 310001
COMPILE_TIME: 7556
SCHEMA_VERSION: 1753864082932160
PL_EVICT_VERSION: 1753864319705488
PS_STMT_ID: -1
DB_ID: 201001
PL_CG_MEM_HOLD: 0
SYS_VARS: 4,BYTE,17180131328,
PARAM_INFOS:
SQL_ID: 1D8E045F2078A97A55B844A07B66B17A
OUTLINE_VERSION: 0
OUTLINE_ID: -1
CONCURRENT_DATA: /*+max_concurrent(-1)*/
1 row in set (0.006 sec)