Use cases

Data tables

Display records in a table format.

Log interfaces

Display logs in tabular format.

Features

All the common API features, plus:

Example

Example 1: Simple data grid query

Get records for the current month ordered by timestamp in descending order.
query DataGridExample1 {
  dataGrid(input: {
    dataPool: {
      name: "TacoSoft Demo Data"
    },
    timeRange: {
      relative: THIS_MONTH
    },
    columns: ["timestamp", "taco_name", "taco_total_price"],
    orderByColumn: 1,
    sort: DESC,
    filters: [],
    first: 3
  }) {
    headers
    rows
    pageInfo {
      hasNextPage
      hasPreviousPage
      endCursor
      startCursor
    }
  }
}

Usage

Arguments

The fields for querying Data Grid records.
dataPool
DataPoolInput
required
The Data Pool to be queried.
timeRange
TimeRangeInput
The time range for retrieving the records.
timeZone
String
The time zone to use. Dates and times are always returned in UTC, but setting the time zone influences relative time ranges and granularities.You can set this to “America/Los_Angeles”, “Europe/Berlin”, or any other value in the IANA time zone database. Defaults to “UTC”.
columns
[String!]
required
The columns to retrieve.
orderByColumn
Int
The index of the column to order the table by. The index is 1-based. If not provided, records will be ordered by their timestamp by default.
sort
Sort
The sort order of the rows. It can be ascending (ASC) or descending (DESC) order. Defaults to descending (DESC) order when not provided.
filterSql
String
The filters to apply to the records, in the form of SQL. You may only filter on columns included in the columns array input.
first
Int
The number of rows to be returned when paging forward. It can be a number between 1 and 1,000.
after
String
The cursor to use when paging forward.
last
Int
The number of rows to be returned when paging forward. It can be a number between 1 and 1,000.
before
String
The cursor to use when paging backward.

Response

The Data Grid table’s node. This type represents a single row of a Data Grid table.
headers
[String!]
required
The Data Grid table’s headers.
row
[String]
required
An array of the values for the row.

Embeddable UI components