Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id CA809200C18 for ; Sat, 28 Jan 2017 07:17:24 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id C902C160B5C; Sat, 28 Jan 2017 06:17:24 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 1E336160B5B for ; Sat, 28 Jan 2017 07:17:23 +0100 (CET) Received: (qmail 76447 invoked by uid 500); 28 Jan 2017 06:17:23 -0000 Mailing-List: contact commits-help@zeppelin.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@zeppelin.apache.org Delivered-To: mailing list commits@zeppelin.apache.org Received: (qmail 76438 invoked by uid 99); 28 Jan 2017 06:17:23 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 28 Jan 2017 06:17:23 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id A6D2DDFC47; Sat, 28 Jan 2017 06:17:22 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit From: minalee@apache.org To: commits@zeppelin.apache.org Message-Id: <707fdb6308d3461391cb660d1b062108@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: =?utf-8?q?zeppelin_git_commit=3A_=5BZEPPELIN-1982=5D_When_using_th?= =?utf-8?b?ZSAnU2VsZWN0ICogLi4uJyBzdGF0ZW1lbnQgZG9lc24ndCBzaG93IOKApg==?= Date: Sat, 28 Jan 2017 06:17:22 +0000 (UTC) archived-at: Sat, 28 Jan 2017 06:17:25 -0000 Repository: zeppelin Updated Branches: refs/heads/master 93e6e0bfc -> 12ab0e5e3 [ZEPPELIN-1982] When using the 'Select * ...' statement doesn't show … ### What is this PR for? In this ticket [ZEPPELIN-212](https://issues.apache.org/jira/browse/ZEPPELIN-212),``InterpreterOutput.java`` will filter out '\n'. It causes ``tabledata.js`` couldn't recognize the comment in the paragraphResult. If column number of sql query exceed 2 columns and row number over ``maxResult`` will show nothing. Therefore, I suppose to modify comment statement from '' to ``TABLE_COMMENT``for this issue. ### What type of PR is it? Bug Fix ### Todos * None ### What is the Jira issue? [ZEPPELIN-1982](https://issues.apache.org/jira/browse/ZEPPELIN-1982) ### How should this be tested? try to execute ``%sql SELECT * FROM bank`` on tutorial ### Screenshots (if appropriate) Before ![2017-01-25 14 49 40](https://cloud.githubusercontent.com/assets/3747345/22279334/8b3e6642-e30d-11e6-9e20-d6da015f016b.png) After ![2017-01-25 14 48 59](https://cloud.githubusercontent.com/assets/3747345/22279909/da0922fa-e310-11e6-9c3e-34ef75b2ac81.png) ### Questions: * Does the licenses files need update? * Is there breaking changes for older versions? * Does this needs documentation? Author: Chin Tzulin Closes #1942 from del680202/bug-1982 and squashes the following commits: 3808964 [Chin Tzulin] Fix problem of livy interpreter e32d7b3 [Chin Tzulin] Fix test problem ba6aab2 [Chin Tzulin] [ZEPPELIN-1982] When using the 'Select * ...' statement doesn't show the response In %sql interpreter Project: http://git-wip-us.apache.org/repos/asf/zeppelin/repo Commit: http://git-wip-us.apache.org/repos/asf/zeppelin/commit/12ab0e5e Tree: http://git-wip-us.apache.org/repos/asf/zeppelin/tree/12ab0e5e Diff: http://git-wip-us.apache.org/repos/asf/zeppelin/diff/12ab0e5e Branch: refs/heads/master Commit: 12ab0e5e3199adb195be332d6cf64200c24a1844 Parents: 93e6e0b Author: Chin Tzulin Authored: Thu Jan 26 15:33:44 2017 +0900 Committer: Mina Lee Committed: Sat Jan 28 15:17:14 2017 +0900 ---------------------------------------------------------------------- .../src/main/java/org/apache/zeppelin/spark/ZeppelinContext.java | 4 +++- zeppelin-web/src/app/tabledata/tabledata.js | 3 ++- 2 files changed, 5 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/zeppelin/blob/12ab0e5e/spark/src/main/java/org/apache/zeppelin/spark/ZeppelinContext.java ---------------------------------------------------------------------- diff --git a/spark/src/main/java/org/apache/zeppelin/spark/ZeppelinContext.java b/spark/src/main/java/org/apache/zeppelin/spark/ZeppelinContext.java index 281a8f8..d1234df 100644 --- a/spark/src/main/java/org/apache/zeppelin/spark/ZeppelinContext.java +++ b/spark/src/main/java/org/apache/zeppelin/spark/ZeppelinContext.java @@ -293,7 +293,9 @@ public class ZeppelinContext { } if (rows.length > maxResult) { - msg.append("\nResults are limited by " + maxResult + "."); + msg.append(""); + msg.append("\n"); + msg.append("Results are limited by " + maxResult + "."); } sc.clearJobGroup(); return msg.toString(); http://git-wip-us.apache.org/repos/asf/zeppelin/blob/12ab0e5e/zeppelin-web/src/app/tabledata/tabledata.js ---------------------------------------------------------------------- diff --git a/zeppelin-web/src/app/tabledata/tabledata.js b/zeppelin-web/src/app/tabledata/tabledata.js index 69fd5dc..950f456 100644 --- a/zeppelin-web/src/app/tabledata/tabledata.js +++ b/zeppelin-web/src/app/tabledata/tabledata.js @@ -37,12 +37,13 @@ export default class TableData { for (var i = 0; i < textRows.length; i++) { var textRow = textRows[i]; + if (commentRow) { comment += textRow; continue; } - if (textRow === '') { + if (textRow === '' || textRow === '') { if (rows.length > 0) { commentRow = true; }