Note
This view is available starting with V4.2.0.
Overview
Displays the file list of external tables created by all tenants.
Columns
Column |
Type |
Is NULL |
Description |
|---|---|---|---|
| TENANT_ID | bigint(20) | NO | Tenant ID |
| TABLE_NAME | varchar(256) | NO | External Table Name |
| TABLE_SCHEMA | varchar(128) | NO | Database name where external table is located |
| PARTITION_NAME | varchar(2) | NO | PARTITION NAME of External Table |
| FILE_URL | varbinary(16384) | NO | File URL of External Table |
| FILE_SIZE | bigint(20) | NO | The size of this file, in bytes. |
Sample query
In the sys tenant, query the external table information of the tenant with ID 1002.
obclient [oceanbase]> SELECT * FROM oceanbase.CDB_OB_EXTERNAL_TABLE_FILES WHERE TENANT_ID = 1002;
The query result is as follows:
+------------+--------------+----------------+------------------------------+-----------+
| TABLE_NAME | TABLE_SCHEMA | PARTITION_NAME | FILE_URL | FILE_SIZE |
+------------+--------------+----------------+------------------------------+-----------+
| ext_t3 | test | P0 | xx.xx.xx.208:2882%data.csv | 34 |
| ext_t2 | test | P0 | xx.xx.xx.208:2882%data.csv | 34 |
| ext_t1 | test | P0 | xx.xx.xx.208:2882%data.csv | 34 |
+------------+--------------+----------------+------------------------------+-----------+
3 rows in set
