- Categories:
System functions (Information)
SYSTEM$SHOW_ BUDGETS_ FOR_ RESOURCE¶
Returns a string containing a list of the budgets that track a specified resource (for example, a table or a schema).
- See also:
语法
实参
'resource_domain'资源的域。您可以指定以下值中的一个:
compute_pooldatabasematerialized_viewpipeschematabletaskwarehouse
'resource_name'资源的名称(例如,表的名称)。
返回
返回一个 VARCHAR 值,其中包含资源预算的完全限定名称的逗号分隔列表。该列表置于方括号之间。
If there are no budgets tracking the specified resource, the function returns a string containing an empty pair of square brackets
([]).
使用说明
该函数的输出包含因以下任意原因而涉及该资源的预算:
- 资源已直接添加到预算中。
- 资源的标签/值组合已添加到预算中。
- 资源属于已添加到预算的对象(例如,数据库)。
示例
The following example returns the list of budgets that track the schema named my_db.my_schema:
The following example returns the list of budgets that track the table named my_db.my_schema.my_table. In this example, the
table is not tracked by any budget, so the function returns an empty list.