Importing Data to the Table

Function

The LOAD DATA function can be used to import data in CSV, Parquet, ORC, JSON, and Avro formats. The data is converted into the Parquet data format for storage.

Syntax

1
2
LOAD DATA INPATH 'folder_path' INTO TABLE [db_name.]table_name
  OPTIONS(property_name=property_value, ...);

Keywords

Parameters

Table 1 Parameters

Parameter

Description

folder_path

OBS path of the file or folder used for storing the raw data.

db_name

Enter the database name. If this parameter is not specified, the current database is used.

table_name

Name of the DLI table to which data is to be imported.

The following configuration options can be used during data import:

Precautions

Example

Before importing data, you must create a table. For details, see Creating an OBS Table or Creating a DLI Table.