Help › Work with results
Draw a chart from a result
Turn a result into a bar, line, area, scatter, pie or histogram chart, choose what it shows, and export it as an image or as data.
Querlyn 0.1.0 is not released yet. This help describes it ahead of release.
Any result with rows can be drawn as a chart. Querlyn suggests one from the columns it finds, and you can change every part of it.
Show the chart
Run a query, then choose Chart in the bar above the grid, the Chart tab of the results pane, or .
The chart opens with its settings at the right, titled Suggested chart. The line at the top left says how many rows are drawn, for example "Chart of 1,000 loaded rows".
What is drawn
The chart draws the rows that are loaded and that the grid shows, in the grid's order. So:
- A filter or sort in the grid applies to the chart too. The line then reads, for example, "Chart of 120 of 1,000 loaded rows (the grid's filter)".
- Rows that are not loaded yet are not in the chart. The line ends "more rows on the server" while there are more.
To bring in more, choose Load More Rows (). Each time it loads 10,000 more rows. It stops at the result's memory limit; see Large results. When a run returned several results, only the last one can load more.
Note: For a chart of a whole large table, let the database do the adding
up: chart a query with GROUP BY rather than loading every row.
What Querlyn suggests
| The result has | Suggested chart |
|---|---|
| A date or time column and numbers | The numbers over time: bars for up to 12 points, a line for more. Many points are grouped by hour, day, week or month. |
| A text or yes/no column with up to 50 different values, and numbers | Bars, one for each value, largest first, with the 20 largest and Other when there are more. |
| Numbers only, two or more columns | A scatter of the second column against the first. |
| One number column | A histogram of it. |
| No number columns | A count of rows. |
Columns that look like identifiers (id, names ending in _id) are not
taken as values. At most four value columns are suggested.
Change the chart
Choose the kind of chart in the chart's bar: Bar, Line, Area, Scatter, Pie or Histogram.
Settings shows and hides the settings (). Which settings are offered depends on the kind of chart:
| Setting | What it chooses |
|---|---|
| Result | Which result of the run to chart, when there are several. |
| X axis | The column along the bottom. |
| Values | The number columns to draw. For a histogram it reads Values to bin. |
| Series from | A column whose values each become a line or a color of bars. |
| Aggregation | What to do with rows that share an X value: None, Sum, Count, Average, Min or Max. |
| Group dates by | Exact value, Hour, Day, Week or Month. |
| Order | Data Order, Largest First, Smallest First or Label A–Z. |
| Show | Every category, or the largest 5, 10, 20, 50 or 100 and Other. |
| Bins | For a histogram: Automatic, or about 5, 10, 20, 50 or 100. |
| Value scale, X scale | Linear or Logarithmic. |
| Stacked, Horizontal bars, Donut | For bars and areas, for bars, and for pies. |
Reset goes back to the suggestion ().
Things to know:
- With Aggregation set to None, each row is its own point. Rows that share an X value are added up, and a note says so.
- Grouping dates adds the values up within each group. Weeks start on Monday. Dates and times are grouped as the grid shows them.
- Whole numbers and decimals are added exactly, without rounding errors.
- NULLs and values that are not numbers are left out, and a note counts them.
- A chart draws at most 8 series, 8 pie slices and 1,000 categories. What is beyond is combined into Other, or a note gives the total. A pie leaves out zero and negative values.
Notes are listed under the settings, or under the chart's bar while the settings are hidden.
Read values from the chart
Point at a bar, a point or a slice to see its exact values.
With the keyboard in the chart:
| Key | Moves |
|---|---|
| ← on macOS or Left on Windows and Linux, → on macOS or Right on Windows and Linux | Between points |
| ↑ on macOS or Up on Windows and Linux, ↓ on macOS or Down on Windows and Linux | Between series at the same point |
| ↖ on macOS or Home on Windows and Linux, ↘ on macOS or End on Windows and Linux | To the first or last point |
| ⎋ on macOS or Esc on Windows and Linux | Takes the mark away |
Export the chart
| To get | Choose |
|---|---|
| An image | PNG… (). The image is twice the size the chart has on screen. |
| A drawing that scales | SVG… () |
| The chart's numbers | Copy Data (), which copies them as CSV |
Exported images use the light colors, also when Querlyn is dark. The numbers copied are the chart's: after adding up and grouping, not the result's rows. To copy rows, see Copy results.
How long a chart lasts
A chart's settings belong to the query tab and last while the tab is open. When you run the query again, the chart is drawn again with the same settings, as long as its columns are still there. If the tab was showing its chart, the next run opens on the chart.
Charts are not kept when you quit, and a saved query does not carry its chart.
Help for Querlyn 0.1.0. All help topics