Creating tables by importing CSV files from AWS S3 in Cloudera Data Warehouse

You can create tables in Hue by importing CSV files stored in S3 buckets. Hue automatically detects the schema and the column types, thus helping you to create tables without using the CREATE TABLE syntax.

The maximum file size supported is three gigabytes.

(Non-RAZ deployment) Only Hue Superusers can access S3 buckets and import files to create tables. To create tables by importing files from S3, you must assign and authorize use of a specific bucket on S3 bucket for your environment. The bucket then appears like a home directory on the Hue web interface.

  1. Sign in to the Cloudera Data Warehouse service.
  2. On the Overview page, select the Virtual Warehouse in which you want to create the table and click on Hue.
  3. From the left assist panel, click on Importer.
  4. On the Importer screen, click .. at the end of the Path field:


    Choose a file pop-up is displayed.
  5. (Non-RAZ deployment) Type s3a:// in the address text box and press enter.
    The S3 buckets associated with the CDW environment are displayed. You can narrow down the list of results using the search option.


    If the file is present on your computer, then you can upload it to S3 by clicking Upload a file. To do this, you must have enabled read/write access to the S3 bucket from the CDW environment.
  6. Select the CSV file that you want to import into Hue.
    Hue displays the preview of the table along with the format:


    Hue automatically detects the field separator, record separator, and the quote character from the CSV file. If you want to override a specific setting, then you can change it by selecting a different value from the drop-down menu.
  7. Click Next.
    On this page, you can set the table destination, partitions, and change the column data types.


  8. Verify the settings and click Submit to create the table.
    The CREATE TABLE query is triggered:


    Hue displays the logs and opens the Table Browser from which you can view the newly created table when the operation completes successfully.