Skip to main content
Basic Usage
{% download data="demo_daily_orders" /%}

Examples

Basic Usage

Basic Usage
{% download data="demo_daily_orders" /%}

Custom Label and Filename

Custom Label and Filename
{% download
  data="demo_daily_orders"
  label="Export Orders"
  filename="daily_orders_export"
/%}

With Variant

With Variant
{% download
  data="demo_daily_orders"
  label="Export Data"
  variant="primary"
/%}

With Large Limit

{% download
  data="demo_daily_orders"
  label="Download Recent Orders"
  limit=50000
/%}

Attributes

data
string
required
Table or view to download
label
string
default:"Download"
Text displayed on the download button
filename
string
Name of the downloaded file (without extension)
variant
string
default:"default"
Button style variantAllowed values:
  • default
  • primary
  • destructive
  • secondary
  • ghost
  • link
filters
array
IDs of filters to apply to the query
where
string
Custom SQL WHERE condition to apply to the query. For date filters, use date_range instead.
having
string
Custom SQL HAVING condition to apply to the query after GROUP BY
limit
number
Maximum number of rows to return from the query. Note: When used with tables, limit will disable subtotals to prevent incomplete subtotal rows.
order
string
Column name(s) with optional direction (e.g. “column_name”, “column_name desc”)
qualify
string
Custom SQL QUALIFY condition to filter windowed results