Before you continue with the upload of the data, you will need to create the tables. In this model, you will have a station master-data table that will be filled with records from this JSON feed: https://feeds.citibikenyc.com/stations/stations.json. You will then create a transactional table for the trips downloaded in the first step.

In order to create the master data table, execute the following SQL command in a new SQL console:

Make sure the result is successful and refresh the CODEJAM schema to make sure your table has been created

Step 3: Insert data into the master data table

You will now insert data into the table using the Insert statement. There are other ways to insert data into tables and you will also use them in this tutorial. Copy and paste and execute the following into a SQL console.

Because the CSV file is too large to manually copy, you will use the IMPORT command to insert data. The file needs to be in a .csv format for the command to work, so upload the file into the /hana/shared/HXE/HDBXX/work/ (where XX is the instance number) directory first:

You can check the data has been imported into the table if no errors have occurred. If errors occur, you will see them in the file you specified after error log. You can also load more datasets if you want a bigger volume to work with.