SQL database inspection and utility functions

Inspect tables and column types, identify the current database, and compare values with Haybarn SQL utility functions.

Choose a function

Use metadata queries when you need to understand a database before querying its data. Restrict results by database and schema to avoid confusing objects with the same name.

Catalog metadata describes the connected engine and loaded extensions. Function availability can differ between the browser runtime and a native installation; select the matching reference snapshot.

Inspect table column names and types

Query column metadata to inspect a table’s column names, declared types, and positions without scanning its rows.

Use column_index to preserve schema order. Filter the database, schema, and table to identify one object.

Inspect table column names and types
SQL
Haybarn WASM 2.0.0-rc12 · In your browser

Guide example · Run to view results.

Expected result
column_namedata_type
productVARCHAR
quantityINTEGER

Watch for: Alphabetical column order is not schema order. Include ORDER BY column_index when generating a schema listing.

Full duckdb_columns() reference →

All database & utility functions

562 functions in Haybarn WASM 2.0.0-rc12. Browse the filtered catalog →