- Categories:
Context functions (General)
SYS_ CONTEXT(SNOWFLAKE$ORGANIZATION 命名空间)¶
返回有关当前组织的信息。
您可以在组织中的任何账户中调用此函数。在任何其他上下文中,该函数返回 NULL。
- See also:
SYS_CONTEXT , SYS_CONTEXT (SNOWFLAKE$APPLICATION namespace) , SYS_CONTEXT (SNOWFLAKE$ENVIRONMENT namespace) , SYS_CONTEXT (SNOWFLAKE$ORGANIZATION_SESSION namespace) , SYS_CONTEXT (SNOWFLAKE$SESSION namespace) , IS_GROUP_ACTIVATED (SYS_CONTEXT function) , IS_GROUP_IMPORTED (SYS_CONTEXT function) , IS_USER_IMPORTED (SYS_CONTEXT function)
语法
用来调用函数的语法:
实参
'SNOWFLAKE$ORGANIZATION'指定您要检索某个属性,或调用某个函数,以返回有关当前组织的上下文信息。
返回
该函数会返回 VARCHAR 值或 NULL:
- The return value depends on the function that you are calling.
- If you call SYS_CONTEXT with the SNOWFLAKE$ORGANIZATION namespace outside of any of the supported contexts, the function returns NULL.
使用说明
-
If you are specifying the function call in a double-quoted string in a shell, escape the
$character with a backslash (\) so that$ORGANIZATIONis not interpreted as a shell variable.For example, if you are using Snowflake CLI and you are specifying the SQL statement as a command-line argument in double quotes:
示例
请参阅以下主题: