aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--examples/src/main/java/org/apache/spark/examples/ml/JavaLDAExample.java2
-rw-r--r--sql/hive/src/test/scala/org/apache/spark/sql/hive/execution/SQLViewSuite.scala8
2 files changed, 5 insertions, 5 deletions
diff --git a/examples/src/main/java/org/apache/spark/examples/ml/JavaLDAExample.java b/examples/src/main/java/org/apache/spark/examples/ml/JavaLDAExample.java
index 7102ddd801..9041244279 100644
--- a/examples/src/main/java/org/apache/spark/examples/ml/JavaLDAExample.java
+++ b/examples/src/main/java/org/apache/spark/examples/ml/JavaLDAExample.java
@@ -53,7 +53,7 @@ public class JavaLDAExample {
double lp = model.logPerplexity(dataset);
System.out.println("The lower bound on the log likelihood of the entire corpus: " + ll);
System.out.println("The upper bound bound on perplexity: " + lp);
-
+
// Describe topics.
Dataset<Row> topics = model.describeTopics(3);
System.out.println("The topics described by their top-weighted terms:");
diff --git a/sql/hive/src/test/scala/org/apache/spark/sql/hive/execution/SQLViewSuite.scala b/sql/hive/src/test/scala/org/apache/spark/sql/hive/execution/SQLViewSuite.scala
index 5c72ec57f5..42dbe188fb 100644
--- a/sql/hive/src/test/scala/org/apache/spark/sql/hive/execution/SQLViewSuite.scala
+++ b/sql/hive/src/test/scala/org/apache/spark/sql/hive/execution/SQLViewSuite.scala
@@ -308,11 +308,11 @@ class SQLViewSuite extends QueryTest with SQLTestUtils with TestHiveSingleton {
test("SPARK-14933 - create view from hive parquet tabale") {
withTable("t_part") {
withView("v_part") {
- sqlContext.sql(
+ spark.sql(
"""create table t_part (c1 int, c2 int)
|stored as parquet as select 1 as a, 2 as b
""".stripMargin)
- sqlContext.sql("create view v_part as select * from t_part")
+ spark.sql("create view v_part as select * from t_part")
checkAnswer(
sql("select * from t_part"),
sql("select * from v_part"))
@@ -323,11 +323,11 @@ class SQLViewSuite extends QueryTest with SQLTestUtils with TestHiveSingleton {
test("SPARK-14933 - create view from hive orc tabale") {
withTable("t_orc") {
withView("v_orc") {
- sqlContext.sql(
+ spark.sql(
"""create table t_orc (c1 int, c2 int)
|stored as orc as select 1 as a, 2 as b
""".stripMargin)
- sqlContext.sql("create view v_orc as select * from t_orc")
+ spark.sql("create view v_orc as select * from t_orc")
checkAnswer(
sql("select * from t_orc"),
sql("select * from v_orc"))