Package dev.frostlake.functions.table
package dev.frostlake.functions.table
-
ClassDescription
INFORMATION_SCHEMA.DATA_METRIC_FUNCTION_REFERENCES— the DATA METRIC FUNCTIONS attached to an object, or the objects one metric is attached to.FLATTEN — expands semi-structured data into one row per element.GENERATOR table function - generates rows with sequential numbers Supports: - ROWCOUNT => n (generates n rows) - TIMELIMIT => seconds (generates rows for specified time period)INFORMATION_SCHEMA.POLICY_REFERENCES— every policy attached to one object, or every object one policy is attached to.The INFORMATION_SCHEMA.QUERY_HISTORY() TABLE FUNCTION — Snowflake exposes query history ONLY this way (SELECT … FROM TABLE(INFORMATION_SCHEMA.QUERY_HISTORY(RESULT_LIMIT => n)); the bare object form is "does not exist", live-verified).Callback a table function uses to run a SQL query text against the engine — the seam that letsToQueryexecute its argument without depending on the executor class itself.RESULT_SCAN table function - retrieves cached query results by query ID.SPLIT_TO_TABLE — splits a string into one row per part, as SEQ, INDEX and VALUE.The INFORMATION_SCHEMA.TAG_REFERENCES(object_name, object_domain) TABLE FUNCTION — the tags attached to one object, asSELECT … FROM TABLE(INFORMATION_SCHEMA.TAG_REFERENCES('db.schema.t', 'TABLE')).INFORMATION_SCHEMA.TASK_HISTORY() table function Syntax: SELECT * FROM TABLE(INFORMATION_SCHEMA.TASK_HISTORY()) SELECT * FROM TABLE(INFORMATION_SCHEMA.TASK_HISTORY(TASK_NAME => 'my_task')) SELECT * FROM TABLE(INFORMATION_SCHEMA.TASK_HISTORY(RESULT_LIMIT => 100))TO_QUERY table function — compiles a SQL text into a query and returns its result set:SELECT * FROM TABLE(TO_QUERY('SELECT ...')).SYSTEM$USER_TASK_CANCEL_ONGOING_EXECUTIONS('task_name')— cancels the runs of a task that are in flight and returns a one-columnstatusrow describing what happened.