[Spark 2060][SQL] Querying JSON Datasets with SQL and DSL in Spark SQL

JIRA: https://issues.apache.org/jira/browse/SPARK-2060
BTW sometimes sample is too expensive because sample isn't by blocks. It still requires reading all the data from disk. You might want to consider sampling by blocks here (or we can improve Spark's sample operator to do that).@mengxr any thoughts?