Prerequisites
To follow the code examples in this guide, you must install Docker locally and download recipes.Navigate to recipe
- If you haven’t already, download recipes.
- In terminal, go to the recipe by running the following command:
Launch Pinot Cluster
You can spin up a Pinot Cluster by running the following command:Dataset
We’re going to import the following CSV files:input/2000_2009/2000_2009.csv
input/2010_2019/2010_2019.csv
input/2020_present/2020_present.csv
Pinot Schema and Table
Now let’s create a Pinot Schema and Table. A common pattern when creating a schema is to create columns that map directly to the names of the fields in our data source. We can’t do that in this case since column names can’t contain spaces, so instead we’ll have the following:config/schema.json
config/table.json*
Ingestion Job
Now we’re going to import the CSV file into Pinot. We’ll do this with the following ingestion spec:config/job-spec.yml
We only need to use this config when importing data for tables that don’t have a timestamp field. If a timestamp field is specified, timestamps are used in the segment name and the likelihood of segments being overridden is reduced.
Querying
Once that’s completed, navigate to localhost:9000/#/query and click on thecrimes table or copy/paste the following query:
Query Results

