Jump to content

Connect SuperML | Leeroopedia MCP: Equip your AI agents with best practices, code verification, and debugging knowledge. Powered by Leeroo — building Organizational Superintelligence. Contact us at founders@leeroo.com.

Principle:Eventual Inc Daft Catalog Context Setting

From Leeroopedia


Knowledge Sources
Domains Data_Engineering, Catalog_Management
Last Updated 2026-02-08 00:00 GMT

Overview

Technique for setting the active catalog and namespace context for name resolution.

Description

Setting the catalog and namespace context determines the default scope for unqualified table references in SQL queries and DataFrame operations. When a catalog is set as current, table operations that require a catalog (such as create_table, list_tables, and drop_table) will use it as the default. Similarly, setting a namespace narrows the scope for table name resolution. Passing None unsets the current catalog or namespace.

Usage

Use catalog context setting when you want to set a default catalog and namespace so that table names resolve without full qualification. This avoids the need to specify catalog.namespace.table for every operation.

Theoretical Basis

Hierarchical name resolution with catalog.namespace.table scoping rules:

Given: set_catalog("my_catalog"), set_namespace("my_ns")

Resolution for unqualified name "my_table":
    -> my_catalog.my_ns.my_table

Resolution for partially qualified name "other_ns.my_table":
    -> my_catalog.other_ns.my_table

Resolution for fully qualified name "other_cat.other_ns.my_table":
    -> other_cat.other_ns.my_table (ignores session defaults)

Related Pages

Implemented By

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment