O'Reilly logo

Effective Amazon Machine Learning by Alexis Perrier

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Creating the database and table directly in SQL

To create the database, run the following query in the query editor:

CREATE DATABASE titanic_db;

Then select titanic_db in the database dropdown menu on the left side as follows:

To create the table and load the data, run the following SQL query:

CREATE EXTERNAL TABLE IF NOT EXISTS titanic_db.titanic (  pclass tinyint,  survived tinyint,  name string,  sex string,  age double,  sibsp tinyint,  parch tinyint,  ticket string,  fare double,  cabin string,  embarked string,  boat string,  body string,  home_dest string ) ROW FORMAT SERDE 'org.apache.hadoop.hive.serde2.lazy.LazySimpleSerDe' WITH SERDEPROPERTIES ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required