Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

please create a Flask application that connects to a MySQL database to add, view, update, and delete data : ) Database Context: Network Device Managment

please create a Flask application that connects to a MySQL
database to add, view, update, and delete data :)
Database Context: Network Device Managment
Database Name: network management db
Tables and Descriptions:
Table: devices
Description: Contains details about network devices managed
by the system.
Fields:
device id (Primary Key, Integer, Auto Increment)
device name (Varchar)
ip address (Varchar, Unique)
device type (Varchar)- e.g., Router, Switch, Firewall
location (Varchar)
status (Varchar)- e.g., Active, Inactive, Under
Maintenance
Table: network logs
Description: Stores logs of network events or changes.
Fields:
log id (Primary Key, Integer, Auto Increment)
device id (Integer, Foreign Key to devices device id)
timestamp (DateTime)
log description (Text)
Table: maintenance records
Description: Records maintenance activities for each device.
Fields:
record id (Primary Key, Integer, Auto Increment)
device id (Integer, Foreign Key to devices device id)
maintenance date (Date)
details (Text)
technician name (Varchar)
Table: users
Description: Contains user accounts who can access or modify the
network device data.
Fields:
user id (Primary Key, Integer, Auto Increment)
username (Varchar, Unique)
password hash (Varchar)
role (Varchar)- e.g., Admin, Technician, Viewer
email (Varchar, Unique)
Relationships:
devices to network_logs: One-to-Many (One device can have
multiple logs)
devices to maintenance records: One-to-Many (One device can
have multiple maintenance records)
CRUD Operations Examples:
Create: Add new network devices, log entries, maintenance records,
or users.
Read: View device details, logs, maintenance history, or user profiles.
Update: Modify device information, update maintenance records, or
change user roles.
Delete: Remove devices, logs, maintenance records, or user account
image text in transcribed

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_2

Step: 3

blur-text-image_3

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

Hands On Database

Authors: Steve Conger

1st Edition

013610827X, 978-0136108276

More Books

Students also viewed these Databases questions

Question

Why do you think it has been successful?

Answered: 1 week ago

Question

a. How will the leader be selected?

Answered: 1 week ago

Question

How many Tables Will Base HCMSs typically have? Why?

Answered: 1 week ago

Question

What is the process of normalization?

Answered: 1 week ago