Skip to content
Snippets Groups Projects
Commit 51997939 authored by Allen Gilliland's avatar Allen Gilliland
Browse files

provide a visual indicator when the result of a query is truncated.

parent 5661ed85
No related branches found
No related tags found
No related merge requests found
......@@ -177,6 +177,16 @@ var QueryVisualization = React.createClass({
data={this.props.result.data} />
);
}
// check if the query result was truncated and let the user know about it if so
if (this.props.result.data.rows_truncated && !rowMaxMessage) {
rowMaxMessage = (
<div className="mt1">
<span className="Badge Badge--headsUp mr2">Too many rows!</span>
Result data was capped at <b>{this.props.result.data.rows_truncated}</b> rows.
</div>
);
}
}
}
......
......@@ -200,7 +200,7 @@
(cond-> {:row_count num-results
:status :completed
:data results}
(= num-results max-result-rows) (assoc :num_results_over_limit true)))) ; so the front-end can let the user know why they're being arbitarily limited
(= num-results max-result-rows) (assoc-in [:data :rows_truncated] max-result-rows)))) ; so the front-end can let the user know why they're being arbitarily limited
;; ### POST-PROCESS
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment