Skip to content

Commit

Permalink
Return alert instead of fetch button when async results has no data
Browse files Browse the repository at this point in the history
  • Loading branch information
vera-liu committed Jan 30, 2017
1 parent 1ac2273 commit d1dc983
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions superset/assets/javascripts/SqlLab/components/ResultSet.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,10 @@ class ResultSet extends React.PureComponent {
</div>
);
} else if (query.resultsKey) {
if (results && data && data.length === 0) {
// if fetched result contains zero rows of data
return <Alert bsStyle="warning">The asynchronous query returned no data</Alert>;
}
return (
<div>
<Alert bsStyle="warning">This query was run asynchronously &nbsp;
Expand Down

0 comments on commit d1dc983

Please sign in to comment.