Loading Data into MariaDB ColumnStore¶

  1. Use MariaDB Client to open a persistent connection to your MariaDB ColumnStore database, and be sure to include the --local-infile option, which is needed by the next step:

    $ mariadb --host --port 5001 \
          --user db_user --password \
          --ssl-verify-server-cert \
          --ssl-ca ~/Downloads/mariadb_chain.pem \
          --default-character-set=utf8 \

    After the command is executed, it will prompt you for a password.

  2. For each table that you want to load, use your MariaDB Client connection to execute the LOAD DATA LOCAL INFILE statement to import the data from the TSV or CSV file into your MariaDB ColumnStore database.

    For a TSV file:

    LOAD DATA LOCAL INFILE 'contacts.tsv'
    INTO TABLE accounts.contacts;

    For a CSV file:

    LOAD DATA LOCAL INFILE 'contacts.csv'
    INTO TABLE accounts.contacts