Skip to content

Instantly share code, notes, and snippets.

View pierre-borckmans's full-sized avatar

Pierre Borckmans pierre-borckmans

View GitHub Profile
screen ~/Library/Containers/com.docker.docker/Data/com.docker.driver.amd64-linux/tty
-------
screen -AmdS docker ~/Library/Containers/com.docker.docker/Data/com.docker.driver.amd64-linux/tty
screen -r docker
# enter, then disconnect with Ctrl-a d
screen -S docker -p 0 -X stuff $(printf root\\r\\n)
screen -r docker
@pierre-borckmans
pierre-borckmans / SelfJoinArrayTypeProblems.scala
Created January 26, 2015 11:11
Spark SQL 1.2.0 - Self join on ArrayType fields problems
import org.apache.spark.sql._
import org.apache.spark.sql.hive.HiveContext
val sqlContext = new HiveContext( sc )
import sqlContext._
// Let's build a table with two columns with types String and Array[String]
val schema = StructType(
Array(
StructField("name", StringType, false),
StructField("friends", ArrayType(StringType, true), false)