Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

You've been given data on passengers of the Titanic in a SQLite file, and you want to create an API that will serve the data

image text in transcribed

You've been given data on passengers of the Titanic in a SQLite file, and you want to create an API that will serve the data in a JSON format. You've created a bare-bones Flask app that connects to the SQLite database and serves a welcome page. Eventually, you will add two endpoints: one that returns a list of all passenger names, and a more detailed endpoint that returns a list of all passengers, including their name, age, and sex. But first, you need a reference to the passenger table in the SQLite database. On line 11, what does Passenger need to have assigned to it so that it will refer to the passenger table in the SQLite database? passenger Base.classes.passenger sqlite: ///titanic.sqlite/passengers Base.tables.passenger

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Oracle Database 10g Insider Solutions

Authors: Arun R. Kumar, John Kanagaraj, Richard Stroupe

1st Edition

0672327910, 978-0672327919

More Books

Students also viewed these Databases questions