Skip to main content
On this page

Kater CLI Explore and try ideas explore card

kater explore card open

Opens a card's query in the Sandbox, as a statement in a scratch file.

Use it to try SQL on a card’s query. It writes the statement to a new scratch file in your brainstorm folder, and runs nothing.

Examples

Terminal window
# Open the card in card.json as a new scratch file
kater explore card open --request-file card.json
# Add the card's statement after the last statement of the scratch file that open.json names as path
kater explore card open --request-file open.json

Options

OptionDescription
--request-file <file>Required. The card as JSON, from a file. - reads stdin. It holds namespace and card. Add path, one of your scratch files, such as connections/snowflake_prod_connection/users/you@example.com/brainstorm/sandbox/live_session_check.sql, to add the statement after its last statement.

It also takes the global options --json, --kater-root, --scope and --help.

What it writes

  • The statement. The card’s query, reading the shared model by its shared name, with the card’s title as its title. Each condition is an optional filter over a parameter that the file declares at the card’s value.
  • The chart. The card’s chart goes in the file’s charts:, when the Sandbox can draw that kind.
  • The answer. The scratch file’s path, the new statement’s number (statement), and where it is in the file (range).

A card that reads a workspace is refused: add it to its workspace instead. A card over another card’s results is refused too: open the card it was built from.

See also