http://git-wip-us.apache.org/repos/asf/incubator-carbondata-site/blob/0d4cdb1c/content/docs/latest/quick_start.html ---------------------------------------------------------------------- diff --git a/content/docs/latest/quick_start.html b/content/docs/latest/quick_start.html deleted file mode 100644 index 8a8db71..0000000 --- a/content/docs/latest/quick_start.html +++ /dev/null @@ -1,250 +0,0 @@ -Untitled Document.md - -

Version: 0.2.0 | Last Published: 21-11-2016

- - Top - - - -

Quick Start

-

This tutorial provides a quick introduction to using CarbonData.

-

Getting started with Apache CarbonData

- - -
-

Installation

- -
-

Interactive Analysis with Carbon-Spark Shell

-

Carbon Spark shell is a wrapper around Apache Spark Shell, it provides a simple way to learn the API, as well as a powerful tool to analyze data interactively. Please visit Apache Spark Documentation for more details on Spark shell.

-
-

Basics

-

Start Carbon Spark shell by running the following command in the CarbonData directory:

-
./bin/carbon-spark-shell
-
-

NOTE: In this shell, SparkContext is readily available as sc and CarbonContext is available as cc.

-

CarbonData stores and writes the data in its specified format at the default location on the hdfs.
-By default, carbon.storelocation is set as:

-
hdfs://IP:PORT/Opt/CarbonStore
-
-

You can provide your own store location by providing configuration using --conf option like:

-
./bin/carbon-spark-sql --conf spark.carbon.storepath=<storelocation>
-
-
-

Executing Queries

-
-

Prerequisites

-

Create a sample.csv file in CarbonData directory using the following commands. The CSV file is required for loading data into CarbonData.

-
$ cd carbondata
-$ cat > sample.csv << EOF
-  id,name,city,age
-  1,david,shenzhen,31
-  2,eason,shenzhen,27
-  3,jarry,wuhan,35
-  EOF
-
-
-

Creating a Table

-
scala>cc.sql("create table if not exists test_table (id string, name string, city string, age Int) STORED BY 'carbondata'")
-
-
-

Loading Data to a Table

-
scala>val dataFilePath = new File("../carbondata/sample.csv").getCanonicalPath
-scala>cc.sql(s"load data inpath '$dataFilePath' into table test_table")
-
-
-

Query Data from a Table

-
scala>cc.sql("select * from test_table").show
-scala>cc.sql("select city, avg(age), sum(age) from test_table group by city").show
-
-
-

CarbonData SQL CLI

-

The CarbonData Spark SQL CLI is a wrapper around Apache Spark SQL CLI. It is a convenient tool to execute queries input from the command line. Please visit Apache Spark Documentation for more information on Apache Spark SQL CLI.

-
-

Basics

-

Start the CarbonData Spark SQL CLI, run the following in the CarbonData directory :

-
./bin/carbon-spark-sql
-
-

CarbonData stores and writes the data in its specified format at the default location on the hdfs.
-By default carbon.storelocation is set as :

-
hdfs://IP:PORT/Opt/CarbonStore
-
-

You can provide your own store location by providing configuration using --conf option like:

-
./bin/carbon-spark-sql --conf spark.carbon.storepath=/home/root/carbonstore
-
-
-

Execute Queries in CLI

-
spark-sql> create table if not exists test_table (id string, name string, city string, age Int) STORED BY 'carbondata'
-spark-sql> load data inpath '../sample.csv' into table test_table
-spark-sql> select city, avg(age), sum(age) from test_table group by city
-
-
-

Building CarbonData

-

To get started, get CarbonData from the downloads section on the http://carbondata.incubator.apache.org.
-CarbonData uses Hadoop’s client libraries for HDFS and YARN and Spark’s libraries. Downloads are pre-packaged for a handful of popular Spark versions.

-

If you’d like to build CarbonData from source, you will need to follow the steps listed below.

-
    -
  1. Before you begin building CarbonData, you need to have prior setup including : - -
  2. -
  3. Clone CarbonData -
    $ git clone https://github.com/apache/incubator-carbondata.git
    -
    -
  4. -
  5. Build the project - -
  6. -
-

Developing CarbonData

-

The developers of CarbonData prefer using Intellij and Eclipse IDE for the development of the Project.
-Following below are steps for configuring the project in IntelliJ IDEA and Eclipse .

-

IntelliJ IDEA

- -

NOTE : While trying to run the scala test, you may get out of memory exception. You need to increase the memory allocated to VM and set as :

-
-XX:MaxPermSize=512m -Xmx3072m
-
-

Eclipse

- -
-Top -
- http://git-wip-us.apache.org/repos/asf/incubator-carbondata-site/blob/0d4cdb1c/content/docs/latest/supported-data-types-in-carbondata.html ---------------------------------------------------------------------- diff --git a/content/docs/latest/supported-data-types-in-carbondata.html b/content/docs/latest/supported-data-types-in-carbondata.html new file mode 100644 index 0000000..da7efb4 --- /dev/null +++ b/content/docs/latest/supported-data-types-in-carbondata.html @@ -0,0 +1,25 @@ +

Data Types

CarbonData supports the following data types:

+ + + + + +