Loading Data into DuckDB
DuckDB is a flexible analytical database that can handle a variety of data types and workloads. A common task when working with DuckDB is loading data from external data sources, such as comma-separated values (CSV), JavaScript Object Notation (JSON), and Apache Parquet files. In this chapter, we will introduce the basic concepts and methods for loading data into DuckDB and provide some examples and best practices to help you get started.
You will learn how to load data into DuckDB from external data sources, how to create tables using SQL commands, and how to load data from various sources and formats, including CSV, JSON, and Parquet files, along with exploring some of the considerations when working with compressed columnar formats. We will also use DuckDB to query and analyze a public dataset, in addition to reviewing how we can export data from DuckDB.
In this chapter, we’re going to cover the following main topics:
- Loading CSV files...