Repository: spark Updated Branches: refs/heads/branch-1.3 e1afd479b -> 4453c591a
[SPARK-6767][SQL] Fixed Query DSL error in spark sql Readme Fixed the following error query.where('key > 30).select(avg('key)).collect() <console>:43: error: value > is not a member of Symbol query.where('key > 30).select(avg('key)).collect() Author: Tijo Thomas <tijopara...@gmail.com> Closes #5415 from tijoparacka/ERROR_SQL_DATAFRAME_EXAMPLE and squashes the following commits: 234751e [Tijo Thomas] Fixed Query DSL error in spark sql Readme (cherry picked from commit 2f482d706b9d38820472c3152dbd1612c98729bd) Signed-off-by: Reynold Xin <r...@databricks.com> Project: http://git-wip-us.apache.org/repos/asf/spark/repo Commit: http://git-wip-us.apache.org/repos/asf/spark/commit/4453c591 Tree: http://git-wip-us.apache.org/repos/asf/spark/tree/4453c591 Diff: http://git-wip-us.apache.org/repos/asf/spark/diff/4453c591 Branch: refs/heads/branch-1.3 Commit: 4453c591a2eaa9381766f6155bfd3e7749f721e0 Parents: e1afd47 Author: Tijo Thomas <tijopara...@gmail.com> Authored: Wed Apr 8 13:42:29 2015 -0700 Committer: Reynold Xin <r...@databricks.com> Committed: Wed Apr 8 13:43:05 2015 -0700 ---------------------------------------------------------------------- sql/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/spark/blob/4453c591/sql/README.md ---------------------------------------------------------------------- diff --git a/sql/README.md b/sql/README.md index a792499..0125de6 100644 --- a/sql/README.md +++ b/sql/README.md @@ -57,6 +57,6 @@ res2: Array[org.apache.spark.sql.Row] = Array([238,val_238], [86,val_86], [311,v You can also build further queries on top of these `DataFrames` using the query DSL. ``` -scala> query.where('key > 30).select(avg('key)).collect() +scala> query.where(query("key") > 30).select(avg(query("key"))).collect() res3: Array[org.apache.spark.sql.Row] = Array([274.79025423728814]) ``` --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@spark.apache.org For additional commands, e-mail: commits-h...@spark.apache.org